@labelbee/lb-components 1.10.0-alpha.2 → 1.10.0-alpha.3
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/App.js +146 -1
- package/dist/App.js.map +1 -0
- package/dist/assets/annotation/common/icon_adapt.svg.js +6 -1
- package/dist/assets/annotation/common/icon_adapt.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_adapt_black.svg.js +6 -1
- package/dist/assets/annotation/common/icon_adapt_black.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_back.svg.js +6 -1
- package/dist/assets/annotation/common/icon_back.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_backA.svg.js +6 -1
- package/dist/assets/annotation/common/icon_backA.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_clear.svg.js +6 -1
- package/dist/assets/annotation/common/icon_clear.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_clearSmall.svg.js +6 -1
- package/dist/assets/annotation/common/icon_clearSmall.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_clearSmall_a.svg.js +6 -1
- package/dist/assets/annotation/common/icon_clearSmall_a.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_clear_a.svg.js +6 -1
- package/dist/assets/annotation/common/icon_clear_a.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_invalid.svg.js +6 -1
- package/dist/assets/annotation/common/icon_invalid.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_invalid_a.svg.js +6 -1
- package/dist/assets/annotation/common/icon_invalid_a.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_next.svg.js +6 -1
- package/dist/assets/annotation/common/icon_next.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_nextA.svg.js +6 -1
- package/dist/assets/annotation/common/icon_nextA.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_r.svg.js +6 -1
- package/dist/assets/annotation/common/icon_r.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_rA.svg.js +6 -1
- package/dist/assets/annotation/common/icon_rA.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_save.svg.js +6 -1
- package/dist/assets/annotation/common/icon_save.svg.js.map +1 -0
- package/dist/assets/annotation/common/icon_saveA.svg.js +6 -1
- package/dist/assets/annotation/common/icon_saveA.svg.js.map +1 -0
- package/dist/assets/annotation/image/brightness.svg.js +6 -1
- package/dist/assets/annotation/image/brightness.svg.js.map +1 -0
- package/dist/assets/annotation/image/contrast.svg.js +6 -1
- package/dist/assets/annotation/image/contrast.svg.js.map +1 -0
- package/dist/assets/annotation/image/icon_yuantu.svg.js +6 -1
- package/dist/assets/annotation/image/icon_yuantu.svg.js.map +1 -0
- package/dist/assets/annotation/image/saturation.svg.js +6 -1
- package/dist/assets/annotation/image/saturation.svg.js.map +1 -0
- package/dist/assets/annotation/lineTool/icon_line.svg.js +6 -1
- package/dist/assets/annotation/lineTool/icon_line.svg.js.map +1 -0
- package/dist/assets/annotation/lineTool/icon_line_a.svg.js +6 -1
- package/dist/assets/annotation/lineTool/icon_line_a.svg.js.map +1 -0
- package/dist/assets/annotation/pointCloudTool/changePointCloudValid.svg.js +6 -1
- package/dist/assets/annotation/pointCloudTool/changePointCloudValid.svg.js.map +1 -0
- package/dist/assets/annotation/pointCloudTool/copy.svg.js +6 -1
- package/dist/assets/annotation/pointCloudTool/copy.svg.js.map +1 -0
- package/dist/assets/annotation/pointCloudTool/nextBox.svg.js +6 -1
- package/dist/assets/annotation/pointCloudTool/nextBox.svg.js.map +1 -0
- package/dist/assets/annotation/pointCloudTool/nodata.svg.js +6 -1
- package/dist/assets/annotation/pointCloudTool/nodata.svg.js.map +1 -0
- package/dist/assets/annotation/pointCloudTool/patse.svg.js +6 -1
- package/dist/assets/annotation/pointCloudTool/patse.svg.js.map +1 -0
- package/dist/assets/annotation/pointCloudTool/prevBox.svg.js +6 -1
- package/dist/assets/annotation/pointCloudTool/prevBox.svg.js.map +1 -0
- package/dist/assets/annotation/pointCloudTool/rotate180_black.svg.js +6 -1
- package/dist/assets/annotation/pointCloudTool/rotate180_black.svg.js.map +1 -0
- package/dist/assets/annotation/pointCloudTool/selectAll.svg.js +6 -1
- package/dist/assets/annotation/pointCloudTool/selectAll.svg.js.map +1 -0
- package/dist/assets/annotation/pointCloudTool/selectMultiple.svg.js +6 -1
- package/dist/assets/annotation/pointCloudTool/selectMultiple.svg.js.map +1 -0
- package/dist/assets/annotation/pointCloudTool/unitAttribute.svg.js +6 -1
- package/dist/assets/annotation/pointCloudTool/unitAttribute.svg.js.map +1 -0
- package/dist/assets/annotation/pointCloudTool/unitAttributeForbid.svg.js +6 -1
- package/dist/assets/annotation/pointCloudTool/unitAttributeForbid.svg.js.map +1 -0
- package/dist/assets/annotation/pointCloudTool/unitAttributeHover.svg.js +6 -1
- package/dist/assets/annotation/pointCloudTool/unitAttributeHover.svg.js.map +1 -0
- package/dist/assets/annotation/pointTool/icon_point.svg.js +6 -1
- package/dist/assets/annotation/pointTool/icon_point.svg.js.map +1 -0
- package/dist/assets/annotation/pointTool/icon_point_a.svg.js +6 -1
- package/dist/assets/annotation/pointTool/icon_point_a.svg.js.map +1 -0
- package/dist/assets/annotation/polygonTool/icon_polygon.svg.js +6 -1
- package/dist/assets/annotation/polygonTool/icon_polygon.svg.js.map +1 -0
- package/dist/assets/annotation/polygonTool/icon_polygon_a.svg.js +6 -1
- package/dist/assets/annotation/polygonTool/icon_polygon_a.svg.js.map +1 -0
- package/dist/assets/annotation/rectTool/icon_rect.svg.js +6 -1
- package/dist/assets/annotation/rectTool/icon_rect.svg.js.map +1 -0
- package/dist/assets/annotation/rectTool/icon_rect_a.svg.js +6 -1
- package/dist/assets/annotation/rectTool/icon_rect_a.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_alttab_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_alttab_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_back_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_back_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_cencel_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_cencel_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_del_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_del_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_forward_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_forward_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_frameActive_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_frameActive_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_frameChange_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_frameChange_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_frameNull_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_frameNull_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_frame_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_frame_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_fullView_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_fullView_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_kj1.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_kj1.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_kj_h.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_kj_h.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_last_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_last_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineActive_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineActive_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineChange_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineChange_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineCont_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineCont_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineDel_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineDel_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineInsert_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineInsert_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineNull_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineNull_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineSpecial_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_lineSpecial_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_line_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_line_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_loupe_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_loupe_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_mouse_left_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_mouse_left_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_mouse_middle_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_mouse_middle_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_mouse_right_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_mouse_right_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_move_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_move_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_next_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_next_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_noDisplay.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_noDisplay.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_playPause.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_playPause.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_pointActive_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_pointActive_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_pointNull_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_pointNull_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_point_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_point_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_polygonActive_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_polygonActive_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_polygonChange_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_polygonChange_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_polygonDel_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_polygonDel_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_polygonInsert_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_polygonInsert_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_polygonMerge_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_polygonMerge_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_polygonNull_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_polygonNull_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_reform_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_reform_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_reload_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_reload_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_save_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_save_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_segment.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_segment.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_speed_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_speed_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_straightLine_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_straightLine_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_tab_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_tab_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_tag_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_tag_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/icon_unGrip_kj.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/icon_unGrip_kj.svg.js.map +1 -0
- package/dist/assets/annotation/toolHotKeyIcon/setValid.svg.js +6 -1
- package/dist/assets/annotation/toolHotKeyIcon/setValid.svg.js.map +1 -0
- package/dist/assets/annotation/video/icon_keyboard_h.svg.js +6 -1
- package/dist/assets/annotation/video/icon_keyboard_h.svg.js.map +1 -0
- package/dist/assets/attributeIcon/eraser.svg.js +6 -1
- package/dist/assets/attributeIcon/eraser.svg.js.map +1 -0
- package/dist/assets/attributeIcon/eraser_a.svg.js +6 -1
- package/dist/assets/attributeIcon/eraser_a.svg.js.map +1 -0
- package/dist/assets/attributeIcon/pen.svg.js +6 -1
- package/dist/assets/attributeIcon/pen.svg.js.map +1 -0
- package/dist/assets/attributeIcon/pen_a.svg.js +6 -1
- package/dist/assets/attributeIcon/pen_a.svg.js.map +1 -0
- package/dist/assets/attributeIcon/zoomUp.svg.js +6 -1
- package/dist/assets/attributeIcon/zoomUp.svg.js.map +1 -0
- package/dist/assets/predictTracking/icon.svg.js +6 -1
- package/dist/assets/predictTracking/icon.svg.js.map +1 -0
- package/dist/assets/toolStyle/icon_border.svg.js +6 -1
- package/dist/assets/toolStyle/icon_border.svg.js.map +1 -0
- package/dist/assets/toolStyle/icon_borderColor.svg.js +6 -1
- package/dist/assets/toolStyle/icon_borderColor.svg.js.map +1 -0
- package/dist/assets/toolStyle/icon_opacityFill.svg.js +6 -1
- package/dist/assets/toolStyle/icon_opacityFill.svg.js.map +1 -0
- package/dist/assets/toolStyle/icon_opacityStroke.svg.js +6 -1
- package/dist/assets/toolStyle/icon_opacityStroke.svg.js.map +1 -0
- package/dist/components/AnnotationView/index.js +160 -1
- package/dist/components/AnnotationView/index.js.map +1 -0
- package/dist/components/AnnotationView/pointCloudAnnotationView.js +85 -1
- package/dist/components/AnnotationView/pointCloudAnnotationView.js.map +1 -0
- package/dist/components/annotationStepPopover/index.js +39 -1
- package/dist/components/annotationStepPopover/index.js.map +1 -0
- package/dist/components/attributeList/index.js +66 -1
- package/dist/components/attributeList/index.js.map +1 -0
- package/dist/components/checkboxList/index.js +39 -1
- package/dist/components/checkboxList/index.js.map +1 -0
- package/dist/components/colorTag/index.js +38 -1
- package/dist/components/colorTag/index.js.map +1 -0
- package/dist/components/customAntd/IconWithText/index.js +59 -1
- package/dist/components/customAntd/IconWithText/index.js.map +1 -0
- package/dist/components/customResizeHook/index.js +95 -1
- package/dist/components/customResizeHook/index.js.map +1 -0
- package/dist/components/fileException/FileError.js +61 -1
- package/dist/components/fileException/FileError.js.map +1 -0
- package/dist/components/fileException/FileInvalid.js +31 -1
- package/dist/components/fileException/FileInvalid.js.map +1 -0
- package/dist/components/fileException/index.js +38 -1
- package/dist/components/fileException/index.js.map +1 -0
- package/dist/components/pointCloudView/PointCloud2DView.js +153 -1
- package/dist/components/pointCloudView/PointCloud2DView.js.map +1 -0
- package/dist/components/pointCloudView/PointCloud3DView.js +234 -1
- package/dist/components/pointCloudView/PointCloud3DView.js.map +1 -0
- package/dist/components/pointCloudView/PointCloudBackView.js +138 -1
- package/dist/components/pointCloudView/PointCloudBackView.js.map +1 -0
- package/dist/components/pointCloudView/PointCloudContext.js +257 -1
- package/dist/components/pointCloudView/PointCloudContext.js.map +1 -0
- package/dist/components/pointCloudView/PointCloudInfos.js +146 -1
- package/dist/components/pointCloudView/PointCloudInfos.js.map +1 -0
- package/dist/components/pointCloudView/PointCloudLayout.js +28 -1
- package/dist/components/pointCloudView/PointCloudLayout.js.map +1 -0
- package/dist/components/pointCloudView/PointCloudListener.js +347 -1
- package/dist/components/pointCloudView/PointCloudListener.js.map +1 -0
- package/dist/components/pointCloudView/PointCloudSegment.js +63 -0
- package/dist/components/pointCloudView/PointCloudSegment.js.map +1 -0
- package/dist/components/pointCloudView/PointCloudSideView.js +135 -1
- package/dist/components/pointCloudView/PointCloudSideView.js.map +1 -0
- package/dist/components/pointCloudView/PointCloudTopView.js +339 -1
- package/dist/components/pointCloudView/PointCloudTopView.js.map +1 -0
- package/dist/components/pointCloudView/components/EmptyPage/index.js +24 -1
- package/dist/components/pointCloudView/components/EmptyPage/index.js.map +1 -0
- package/dist/components/pointCloudView/components/UnifyParamsModal/index.js +240 -1
- package/dist/components/pointCloudView/components/UnifyParamsModal/index.js.map +1 -0
- package/dist/components/pointCloudView/hooks/useAttribute.js +53 -1
- package/dist/components/pointCloudView/hooks/useAttribute.js.map +1 -0
- package/dist/components/pointCloudView/hooks/useBoxes.js +81 -1
- package/dist/components/pointCloudView/hooks/useBoxes.js.map +1 -0
- package/dist/components/pointCloudView/hooks/useConfig.js +33 -1
- package/dist/components/pointCloudView/hooks/useConfig.js.map +1 -0
- package/dist/components/pointCloudView/hooks/useHistory.js +173 -1
- package/dist/components/pointCloudView/hooks/useHistory.js.map +1 -0
- package/dist/components/pointCloudView/hooks/useLine.js +74 -1
- package/dist/components/pointCloudView/hooks/useLine.js.map +1 -0
- package/dist/components/pointCloudView/hooks/usePointCloudViews.js +759 -1
- package/dist/components/pointCloudView/hooks/usePointCloudViews.js.map +1 -0
- package/dist/components/pointCloudView/hooks/usePolygon.js +74 -1
- package/dist/components/pointCloudView/hooks/usePolygon.js.map +1 -0
- package/dist/components/pointCloudView/hooks/useRotate.js +47 -1
- package/dist/components/pointCloudView/hooks/useRotate.js.map +1 -0
- package/dist/components/pointCloudView/hooks/useSingleBox.js +176 -1
- package/dist/components/pointCloudView/hooks/useSingleBox.js.map +1 -0
- package/dist/components/pointCloudView/hooks/useSphere.js +51 -1
- package/dist/components/pointCloudView/hooks/useSphere.js.map +1 -0
- package/dist/components/pointCloudView/hooks/useStatus.js +92 -1
- package/dist/components/pointCloudView/hooks/useStatus.js.map +1 -0
- package/dist/components/pointCloudView/hooks/useZoom.js +42 -1
- package/dist/components/pointCloudView/hooks/useZoom.js.map +1 -0
- package/dist/components/pointCloudView/index.js +59 -1
- package/dist/components/pointCloudView/index.js.map +1 -0
- package/dist/components/predictTracking/index.js +8 -1
- package/dist/components/predictTracking/index.js.map +1 -0
- package/dist/components/predictTracking/predictTrackingIcon/index.js +97 -1
- package/dist/components/predictTracking/predictTrackingIcon/index.js.map +1 -0
- package/dist/components/predictTracking/previewResult/index.js +196 -1
- package/dist/components/predictTracking/previewResult/index.js.map +1 -0
- package/dist/components/predictTracking/previewResult/util.js +143 -1
- package/dist/components/predictTracking/previewResult/util.js.map +1 -0
- package/dist/components/videoAnnotate/index.js +50 -1
- package/dist/components/videoAnnotate/index.js.map +1 -0
- package/dist/components/videoPlayer/TagToolInstanceAdaptor.js +233 -1
- package/dist/components/videoPlayer/TagToolInstanceAdaptor.js.map +1 -0
- package/dist/components/videoPlayer/TagToolInstanceAdaptorI18nProvider.js +40 -1
- package/dist/components/videoPlayer/TagToolInstanceAdaptorI18nProvider.js.map +1 -0
- package/dist/components/videoPlayer/VideoTagLayer.js +37 -1
- package/dist/components/videoPlayer/VideoTagLayer.js.map +1 -0
- package/dist/components/videoPlayer/components/controller/index.js +131 -1
- package/dist/components/videoPlayer/components/controller/index.js.map +1 -0
- package/dist/components/videoPlayer/index.js +267 -1
- package/dist/components/videoPlayer/index.js.map +1 -0
- package/dist/components/videoPlayer/utils.js +59 -1
- package/dist/components/videoPlayer/utils.js.map +1 -0
- package/dist/configureStore.js +16 -1
- package/dist/configureStore.js.map +1 -0
- package/dist/constant/index.js +32 -1
- package/dist/constant/index.js.map +1 -0
- package/dist/constant/styleString.js +6 -1
- package/dist/constant/styleString.js.map +1 -0
- package/dist/data/Style.js +113 -1
- package/dist/data/Style.js.map +1 -0
- package/dist/data/enums/AnnotationSize.js +39 -1
- package/dist/data/enums/AnnotationSize.js.map +1 -0
- package/dist/data/enums/ToolType.js +44 -1
- package/dist/data/enums/ToolType.js.map +1 -0
- package/dist/hooks/annotation.js +81 -1
- package/dist/hooks/annotation.js.map +1 -0
- package/dist/hooks/useRafState.js +21 -1
- package/dist/hooks/useRafState.js.map +1 -0
- package/dist/hooks/useRefCache.js +14 -1
- package/dist/hooks/useRefCache.js.map +1 -0
- package/dist/hooks/useSafeSate.js +22 -1
- package/dist/hooks/useSafeSate.js.map +1 -0
- package/dist/hooks/useSize.js +45 -1
- package/dist/hooks/useSize.js.map +1 -0
- package/dist/hooks/useUnmountedRef.js +17 -1
- package/dist/hooks/useUnmountedRef.js.map +1 -0
- package/dist/index.js +90 -1
- package/dist/index.js.map +1 -0
- package/dist/store/Actions.js +57 -1
- package/dist/store/Actions.js.map +1 -0
- package/dist/store/annotation/actionCreators.js +488 -1
- package/dist/store/annotation/actionCreators.js.map +1 -0
- package/dist/store/annotation/map.js +26 -1
- package/dist/store/annotation/map.js.map +1 -0
- package/dist/store/annotation/reducer.js +669 -1
- package/dist/store/annotation/reducer.js.map +1 -0
- package/dist/store/annotation/selectors.js +15 -1
- package/dist/store/annotation/selectors.js.map +1 -0
- package/dist/store/ctx.js +19 -1
- package/dist/store/ctx.js.map +1 -0
- package/dist/store/imgAttribute/actionCreators.js +27 -1
- package/dist/store/imgAttribute/actionCreators.js.map +1 -0
- package/dist/store/imgAttribute/reducer.js +44 -1
- package/dist/store/imgAttribute/reducer.js.map +1 -0
- package/dist/store/index.js +17 -1
- package/dist/store/index.js.map +1 -0
- package/dist/store/toolStyle/actionCreators.js +22 -1
- package/dist/store/toolStyle/actionCreators.js.map +1 -0
- package/dist/store/toolStyle/reducer.js +54 -1
- package/dist/store/toolStyle/reducer.js.map +1 -0
- package/dist/utils/AnnotationDataUtils.js +171 -1
- package/dist/utils/AnnotationDataUtils.js.map +1 -0
- package/dist/utils/ConfigUtils.js +22 -1
- package/dist/utils/ConfigUtils.js.map +1 -0
- package/dist/utils/PageOperator.js +99 -1
- package/dist/utils/PageOperator.js.map +1 -0
- package/dist/utils/StepUtils.js +29 -1
- package/dist/utils/StepUtils.js.map +1 -0
- package/dist/utils/TextUtils.js +45 -1
- package/dist/utils/TextUtils.js.map +1 -0
- package/dist/utils/ToolStyleUtils.js +96 -1
- package/dist/utils/ToolStyleUtils.js.map +1 -0
- package/dist/utils/ToolUtils.js +19 -1
- package/dist/utils/ToolUtils.js.map +1 -0
- package/dist/utils/data.js +77 -1
- package/dist/utils/data.js.map +1 -0
- package/dist/utils/dom.js +25 -1
- package/dist/utils/dom.js.map +1 -0
- package/dist/utils/index.js +39 -1
- package/dist/utils/index.js.map +1 -0
- package/dist/views/MainView/annotationOperation/index.js +175 -1
- package/dist/views/MainView/annotationOperation/index.js.map +1 -0
- package/dist/views/MainView/annotationTips/index.js +32 -1
- package/dist/views/MainView/annotationTips/index.js.map +1 -0
- package/dist/views/MainView/index.js +122 -1
- package/dist/views/MainView/index.js.map +1 -0
- package/dist/views/MainView/sidebar/AnnotationText/index.js +47 -1
- package/dist/views/MainView/sidebar/AnnotationText/index.js.map +1 -0
- package/dist/views/MainView/sidebar/ClearIcon/index.js +37 -1
- package/dist/views/MainView/sidebar/ClearIcon/index.js.map +1 -0
- package/dist/views/MainView/sidebar/GeneralOperation/ActionsConfirm.js +101 -1
- package/dist/views/MainView/sidebar/GeneralOperation/ActionsConfirm.js.map +1 -0
- package/dist/views/MainView/sidebar/GeneralOperation/index.js +95 -1
- package/dist/views/MainView/sidebar/GeneralOperation/index.js.map +1 -0
- package/dist/views/MainView/sidebar/GeneralOperation/useOperationList.js +94 -1
- package/dist/views/MainView/sidebar/GeneralOperation/useOperationList.js.map +1 -0
- package/dist/views/MainView/sidebar/ImgAttributeInfo/index.js +134 -1
- package/dist/views/MainView/sidebar/ImgAttributeInfo/index.js.map +1 -0
- package/dist/views/MainView/sidebar/PointCloudToolSidebar/components/batchUpdateModal/index.js +128 -1
- package/dist/views/MainView/sidebar/PointCloudToolSidebar/components/batchUpdateModal/index.js.map +1 -0
- package/dist/views/MainView/sidebar/PointCloudToolSidebar/index.js +253 -1
- package/dist/views/MainView/sidebar/PointCloudToolSidebar/index.js.map +1 -0
- package/dist/views/MainView/sidebar/ScribbleSidebar/index.js +64 -1
- package/dist/views/MainView/sidebar/ScribbleSidebar/index.js.map +1 -0
- package/dist/views/MainView/sidebar/SwitchAttributeList/index.js +79 -1
- package/dist/views/MainView/sidebar/SwitchAttributeList/index.js.map +1 -0
- package/dist/views/MainView/sidebar/TagSidebar/index.js +187 -1
- package/dist/views/MainView/sidebar/TagSidebar/index.js.map +1 -0
- package/dist/views/MainView/sidebar/TextAreaFormat/index.js +112 -1
- package/dist/views/MainView/sidebar/TextAreaFormat/index.js.map +1 -0
- package/dist/views/MainView/sidebar/TextToolSidebar/index.js +235 -1
- package/dist/views/MainView/sidebar/TextToolSidebar/index.js.map +1 -0
- package/dist/views/MainView/sidebar/ToolIcons.js +87 -1
- package/dist/views/MainView/sidebar/ToolIcons.js.map +1 -0
- package/dist/views/MainView/sidebar/ToolStyle/index.js +162 -1
- package/dist/views/MainView/sidebar/ToolStyle/index.js.map +1 -0
- package/dist/views/MainView/sidebar/index.js +156 -1
- package/dist/views/MainView/sidebar/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/AnnotatedAttributes/index.js +211 -1
- package/dist/views/MainView/toolFooter/AnnotatedAttributes/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterPopover.js +54 -1
- package/dist/views/MainView/toolFooter/FooterPopover.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/common/index.js +149 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/common/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/cuboid/index.js +26 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/cuboid/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/index.js +226 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/line/index.js +111 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/line/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/point/index.js +55 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/point/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/pointCloud/index.js +174 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/pointCloud/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/polygon/index.js +117 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/polygon/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/rectToolShortCutTable/index.js +71 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/rectToolShortCutTable/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/scribble/index.js +18 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/scribble/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/tag/index.js +25 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/tag/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/text/index.js +18 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/text/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/videoTag/index.js +28 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/videoTag/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/FooterTips/index.js +23 -1
- package/dist/views/MainView/toolFooter/FooterTips/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/HiddenTips/index.js +45 -1
- package/dist/views/MainView/toolFooter/HiddenTips/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/PageNumber/index.js +48 -1
- package/dist/views/MainView/toolFooter/PageNumber/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/Pagination.js +91 -1
- package/dist/views/MainView/toolFooter/Pagination.js.map +1 -0
- package/dist/views/MainView/toolFooter/ZoomController/ZoomLevel/index.js +39 -1
- package/dist/views/MainView/toolFooter/ZoomController/ZoomLevel/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/ZoomController/index.js +72 -1
- package/dist/views/MainView/toolFooter/ZoomController/index.js.map +1 -0
- package/dist/views/MainView/toolFooter/index.js +135 -1
- package/dist/views/MainView/toolFooter/index.js.map +1 -0
- package/dist/views/MainView/toolHeader/ExportData/index.js +44 -1
- package/dist/views/MainView/toolHeader/ExportData/index.js.map +1 -0
- package/dist/views/MainView/toolHeader/StepSwitch/index.js +47 -1
- package/dist/views/MainView/toolHeader/StepSwitch/index.js.map +1 -0
- package/dist/views/MainView/toolHeader/SwitchPattern/index.js +59 -0
- package/dist/views/MainView/toolHeader/SwitchPattern/index.js.map +1 -0
- package/dist/views/MainView/toolHeader/headerOption/index.js +151 -1
- package/dist/views/MainView/toolHeader/headerOption/index.js.map +1 -0
- package/dist/views/MainView/toolHeader/index.js +180 -1
- package/dist/views/MainView/toolHeader/index.js.map +1 -0
- package/es/App.js +138 -1
- package/es/App.js.map +1 -0
- package/es/assets/annotation/common/icon_adapt.svg.js +4 -1
- package/es/assets/annotation/common/icon_adapt.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_adapt_black.svg.js +4 -1
- package/es/assets/annotation/common/icon_adapt_black.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_back.svg.js +4 -1
- package/es/assets/annotation/common/icon_back.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_backA.svg.js +4 -1
- package/es/assets/annotation/common/icon_backA.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_clear.svg.js +4 -1
- package/es/assets/annotation/common/icon_clear.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_clearSmall.svg.js +4 -1
- package/es/assets/annotation/common/icon_clearSmall.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_clearSmall_a.svg.js +4 -1
- package/es/assets/annotation/common/icon_clearSmall_a.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_clear_a.svg.js +4 -1
- package/es/assets/annotation/common/icon_clear_a.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_invalid.svg.js +4 -1
- package/es/assets/annotation/common/icon_invalid.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_invalid_a.svg.js +4 -1
- package/es/assets/annotation/common/icon_invalid_a.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_next.svg.js +4 -1
- package/es/assets/annotation/common/icon_next.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_nextA.svg.js +4 -1
- package/es/assets/annotation/common/icon_nextA.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_r.svg.js +4 -1
- package/es/assets/annotation/common/icon_r.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_rA.svg.js +4 -1
- package/es/assets/annotation/common/icon_rA.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_save.svg.js +4 -1
- package/es/assets/annotation/common/icon_save.svg.js.map +1 -0
- package/es/assets/annotation/common/icon_saveA.svg.js +4 -1
- package/es/assets/annotation/common/icon_saveA.svg.js.map +1 -0
- package/es/assets/annotation/image/brightness.svg.js +4 -1
- package/es/assets/annotation/image/brightness.svg.js.map +1 -0
- package/es/assets/annotation/image/contrast.svg.js +4 -1
- package/es/assets/annotation/image/contrast.svg.js.map +1 -0
- package/es/assets/annotation/image/icon_yuantu.svg.js +4 -1
- package/es/assets/annotation/image/icon_yuantu.svg.js.map +1 -0
- package/es/assets/annotation/image/saturation.svg.js +4 -1
- package/es/assets/annotation/image/saturation.svg.js.map +1 -0
- package/es/assets/annotation/lineTool/icon_line.svg.js +4 -1
- package/es/assets/annotation/lineTool/icon_line.svg.js.map +1 -0
- package/es/assets/annotation/lineTool/icon_line_a.svg.js +4 -1
- package/es/assets/annotation/lineTool/icon_line_a.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/changePointCloudValid.svg.js +4 -1
- package/es/assets/annotation/pointCloudTool/changePointCloudValid.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/copy.svg.js +4 -1
- package/es/assets/annotation/pointCloudTool/copy.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/nextBox.svg.js +4 -1
- package/es/assets/annotation/pointCloudTool/nextBox.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/nodata.svg.js +4 -1
- package/es/assets/annotation/pointCloudTool/nodata.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/patse.svg.js +4 -1
- package/es/assets/annotation/pointCloudTool/patse.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/prevBox.svg.js +4 -1
- package/es/assets/annotation/pointCloudTool/prevBox.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/rotate180_black.svg.js +4 -1
- package/es/assets/annotation/pointCloudTool/rotate180_black.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/selectAll.svg.js +4 -1
- package/es/assets/annotation/pointCloudTool/selectAll.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/selectMultiple.svg.js +4 -1
- package/es/assets/annotation/pointCloudTool/selectMultiple.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/unitAttribute.svg.js +4 -1
- package/es/assets/annotation/pointCloudTool/unitAttribute.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/unitAttributeForbid.svg.js +4 -1
- package/es/assets/annotation/pointCloudTool/unitAttributeForbid.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/unitAttributeHover.svg.js +4 -1
- package/es/assets/annotation/pointCloudTool/unitAttributeHover.svg.js.map +1 -0
- package/es/assets/annotation/pointTool/icon_point.svg.js +4 -1
- package/es/assets/annotation/pointTool/icon_point.svg.js.map +1 -0
- package/es/assets/annotation/pointTool/icon_point_a.svg.js +4 -1
- package/es/assets/annotation/pointTool/icon_point_a.svg.js.map +1 -0
- package/es/assets/annotation/polygonTool/icon_polygon.svg.js +4 -1
- package/es/assets/annotation/polygonTool/icon_polygon.svg.js.map +1 -0
- package/es/assets/annotation/polygonTool/icon_polygon_a.svg.js +4 -1
- package/es/assets/annotation/polygonTool/icon_polygon_a.svg.js.map +1 -0
- package/es/assets/annotation/rectTool/icon_rect.svg.js +4 -1
- package/es/assets/annotation/rectTool/icon_rect.svg.js.map +1 -0
- package/es/assets/annotation/rectTool/icon_rectPattern.svg.js +4 -0
- package/es/assets/annotation/rectTool/icon_rectPattern.svg.js.map +1 -0
- package/es/assets/annotation/rectTool/icon_rect_a.svg.js +4 -1
- package/es/assets/annotation/rectTool/icon_rect_a.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_alttab_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_alttab_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_back_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_back_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_cencel_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_cencel_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_copyBackwardResult.svg.js +4 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_copyBackwardResult.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_del_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_del_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_forward_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_forward_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_frameActive_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_frameActive_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_frameChange_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_frameChange_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_frameNull_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_frameNull_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_frame_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_frame_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_fullView_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_fullView_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_kj1.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_kj1.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_kj_h.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_kj_h.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_last_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_last_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_lineActive_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_lineActive_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_lineChange_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_lineChange_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_lineCont_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_lineCont_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_lineDel_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_lineDel_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_lineInsert_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_lineInsert_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_lineNull_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_lineNull_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_lineSpecial_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_lineSpecial_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_line_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_line_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_loupe_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_loupe_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_mouse_left_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_mouse_left_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_mouse_middle_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_mouse_middle_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_mouse_right_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_mouse_right_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_move_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_move_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_next_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_next_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_noDisplay.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_noDisplay.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_playPause.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_playPause.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_pointActive_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_pointActive_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_pointNull_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_pointNull_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_point_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_point_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_polygonActive_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_polygonActive_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_polygonChange_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_polygonChange_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_polygonDel_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_polygonDel_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_polygonInsert_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_polygonInsert_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_polygonMerge_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_polygonMerge_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_polygonNull_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_polygonNull_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_reform_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_reform_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_reload_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_reload_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_save_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_save_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_segment.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_segment.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_speed_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_speed_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_straightLine_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_straightLine_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_tab_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_tab_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_tag_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_tag_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/icon_unGrip_kj.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/icon_unGrip_kj.svg.js.map +1 -0
- package/es/assets/annotation/toolHotKeyIcon/setValid.svg.js +4 -1
- package/es/assets/annotation/toolHotKeyIcon/setValid.svg.js.map +1 -0
- package/es/assets/annotation/video/icon_keyboard_h.svg.js +4 -1
- package/es/assets/annotation/video/icon_keyboard_h.svg.js.map +1 -0
- package/es/assets/attributeIcon/eraser.svg.js +4 -1
- package/es/assets/attributeIcon/eraser.svg.js.map +1 -0
- package/es/assets/attributeIcon/eraser_a.svg.js +4 -1
- package/es/assets/attributeIcon/eraser_a.svg.js.map +1 -0
- package/es/assets/attributeIcon/pen.svg.js +4 -1
- package/es/assets/attributeIcon/pen.svg.js.map +1 -0
- package/es/assets/attributeIcon/pen_a.svg.js +4 -1
- package/es/assets/attributeIcon/pen_a.svg.js.map +1 -0
- package/es/assets/attributeIcon/zoomUp.svg.js +4 -1
- package/es/assets/attributeIcon/zoomUp.svg.js.map +1 -0
- package/es/assets/cssIcon/annotation/icon_clearSmall.svg +10 -0
- package/es/assets/cssIcon/annotation/icon_clearSmall_a.svg +10 -0
- package/es/assets/cssIcon/slide_btn.svg +23 -0
- package/es/assets/predictTracking/icon.svg.js +4 -1
- package/es/assets/predictTracking/icon.svg.js.map +1 -0
- package/es/assets/toolStyle/icon_border.svg.js +4 -1
- package/es/assets/toolStyle/icon_border.svg.js.map +1 -0
- package/es/assets/toolStyle/icon_borderColor.svg.js +4 -1
- package/es/assets/toolStyle/icon_borderColor.svg.js.map +1 -0
- package/es/assets/toolStyle/icon_opacityFill.svg.js +4 -1
- package/es/assets/toolStyle/icon_opacityFill.svg.js.map +1 -0
- package/es/assets/toolStyle/icon_opacityStroke.svg.js +4 -1
- package/es/assets/toolStyle/icon_opacityStroke.svg.js.map +1 -0
- package/es/components/AnnotationView/index.js +154 -1
- package/es/components/AnnotationView/index.js.map +1 -0
- package/es/components/AnnotationView/pointCloudAnnotationView.js +79 -1
- package/es/components/AnnotationView/pointCloudAnnotationView.js.map +1 -0
- package/es/components/ImageError/index.js +53 -0
- package/es/components/ImageError/index.js.map +1 -0
- package/es/components/annotationStepPopover/index.js +33 -1
- package/es/components/annotationStepPopover/index.js.map +1 -0
- package/es/components/attributeList/index.js +57 -1
- package/es/components/attributeList/index.js.map +1 -0
- package/es/components/checkboxList/index.js +33 -1
- package/es/components/checkboxList/index.js.map +1 -0
- package/es/components/colorTag/index.js +30 -1
- package/es/components/colorTag/index.js.map +1 -0
- package/es/components/customAntd/IconWithText/index.js +53 -1
- package/es/components/customAntd/IconWithText/index.js.map +1 -0
- package/es/components/customResizeHook/index.js +84 -1
- package/es/components/customResizeHook/index.js.map +1 -0
- package/es/components/fileException/FileError.js +55 -1
- package/es/components/fileException/FileError.js.map +1 -0
- package/es/components/fileException/FileInvalid.js +25 -1
- package/es/components/fileException/FileInvalid.js.map +1 -0
- package/es/components/fileException/index.js +32 -1
- package/es/components/fileException/index.js.map +1 -0
- package/es/components/pointCloudView/PointCloud2DView.js +147 -1
- package/es/components/pointCloudView/PointCloud2DView.js.map +1 -0
- package/es/components/pointCloudView/PointCloud3DView.js +227 -1
- package/es/components/pointCloudView/PointCloud3DView.js.map +1 -0
- package/es/components/pointCloudView/PointCloudBackView.js +132 -1
- package/es/components/pointCloudView/PointCloudBackView.js.map +1 -0
- package/es/components/pointCloudView/PointCloudContext.js +248 -1
- package/es/components/pointCloudView/PointCloudContext.js.map +1 -0
- package/es/components/pointCloudView/PointCloudInfos.js +136 -1
- package/es/components/pointCloudView/PointCloudInfos.js.map +1 -0
- package/es/components/pointCloudView/PointCloudLayout.js +19 -1
- package/es/components/pointCloudView/PointCloudLayout.js.map +1 -0
- package/es/components/pointCloudView/PointCloudListener.js +345 -1
- package/es/components/pointCloudView/PointCloudListener.js.map +1 -0
- package/es/components/pointCloudView/PointCloudSegment.js +57 -0
- package/es/components/pointCloudView/PointCloudSegment.js.map +1 -0
- package/es/components/pointCloudView/PointCloudSideView.js +129 -1
- package/es/components/pointCloudView/PointCloudSideView.js.map +1 -0
- package/es/components/pointCloudView/PointCloudTopView.js +333 -1
- package/es/components/pointCloudView/PointCloudTopView.js.map +1 -0
- package/es/components/pointCloudView/components/EmptyPage/index.js +18 -1
- package/es/components/pointCloudView/components/EmptyPage/index.js.map +1 -0
- package/es/components/pointCloudView/components/PointCloudSizeSlider/index.js +23 -0
- package/es/components/pointCloudView/components/PointCloudSizeSlider/index.js.map +1 -0
- package/es/components/pointCloudView/components/UnifiedParamsModal/index.js +228 -0
- package/es/components/pointCloudView/components/UnifiedParamsModal/index.js.map +1 -0
- package/es/components/pointCloudView/components/UnifyParamsModal/index.js +234 -1
- package/es/components/pointCloudView/components/UnifyParamsModal/index.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/useAttribute.js +49 -1
- package/es/components/pointCloudView/hooks/useAttribute.js.map +1 -0
- package/es/components/pointCloudView/hooks/useBoxes.js +73 -1
- package/es/components/pointCloudView/hooks/useBoxes.js.map +1 -0
- package/es/components/pointCloudView/hooks/useConfig.js +29 -1
- package/es/components/pointCloudView/hooks/useConfig.js.map +1 -0
- package/es/components/pointCloudView/hooks/useHistory.js +169 -1
- package/es/components/pointCloudView/hooks/useHistory.js.map +1 -0
- package/es/components/pointCloudView/hooks/useLine.js +70 -1
- package/es/components/pointCloudView/hooks/useLine.js.map +1 -0
- package/es/components/pointCloudView/hooks/usePointCloudViews.js +747 -1
- package/es/components/pointCloudView/hooks/usePointCloudViews.js.map +1 -0
- package/es/components/pointCloudView/hooks/usePolygon.js +70 -1
- package/es/components/pointCloudView/hooks/usePolygon.js.map +1 -0
- package/es/components/pointCloudView/hooks/useRotate.js +43 -1
- package/es/components/pointCloudView/hooks/useRotate.js.map +1 -0
- package/es/components/pointCloudView/hooks/useSingleBox.js +168 -1
- package/es/components/pointCloudView/hooks/useSingleBox.js.map +1 -0
- package/es/components/pointCloudView/hooks/useSphere.js +43 -1
- package/es/components/pointCloudView/hooks/useSphere.js.map +1 -0
- package/es/components/pointCloudView/hooks/useStatus.js +88 -1
- package/es/components/pointCloudView/hooks/useStatus.js.map +1 -0
- package/es/components/pointCloudView/hooks/useZoom.js +38 -1
- package/es/components/pointCloudView/hooks/useZoom.js.map +1 -0
- package/es/components/pointCloudView/index.js +53 -1
- package/es/components/pointCloudView/index.js.map +1 -0
- package/es/components/predictTracking/index.js +3 -1
- package/es/components/predictTracking/index.js.map +1 -0
- package/es/components/predictTracking/predictTrackingIcon/index.js +91 -1
- package/es/components/predictTracking/predictTrackingIcon/index.js.map +1 -0
- package/es/components/predictTracking/previewResult/index.js +189 -1
- package/es/components/predictTracking/previewResult/index.js.map +1 -0
- package/es/components/predictTracking/previewResult/util.js +135 -1
- package/es/components/predictTracking/previewResult/util.js.map +1 -0
- package/es/components/videoAnnotate/index.js +44 -1
- package/es/components/videoAnnotate/index.js.map +1 -0
- package/es/components/videoPlayer/TagToolInstanceAdaptor.js +224 -1
- package/es/components/videoPlayer/TagToolInstanceAdaptor.js.map +1 -0
- package/es/components/videoPlayer/TagToolInstanceAdaptorI18nProvider.js +32 -1
- package/es/components/videoPlayer/TagToolInstanceAdaptorI18nProvider.js.map +1 -0
- package/es/components/videoPlayer/VideoTagLayer.js +29 -1
- package/es/components/videoPlayer/VideoTagLayer.js.map +1 -0
- package/es/components/videoPlayer/components/controller/index.js +125 -1
- package/es/components/videoPlayer/components/controller/index.js.map +1 -0
- package/es/components/videoPlayer/index.js +257 -1
- package/es/components/videoPlayer/index.js.map +1 -0
- package/es/components/videoPlayer/utils.js +51 -1
- package/es/components/videoPlayer/utils.js.map +1 -0
- package/es/configureStore.js +10 -1
- package/es/configureStore.js.map +1 -0
- package/es/constant/index.js +27 -1
- package/es/constant/index.js.map +1 -0
- package/es/constant/styleString.js +4 -1
- package/es/constant/styleString.js.map +1 -0
- package/es/data/Style.js +104 -1
- package/es/data/Style.js.map +1 -0
- package/es/data/enums/AnnotationSize.js +32 -1
- package/es/data/enums/AnnotationSize.js.map +1 -0
- package/es/data/enums/ToolType.js +40 -1
- package/es/data/enums/ToolType.js.map +1 -0
- package/es/hooks/annotation.js +77 -1
- package/es/hooks/annotation.js.map +1 -0
- package/es/hooks/useConfig.js +18 -0
- package/es/hooks/useConfig.js.map +1 -0
- package/es/hooks/useRafState.js +19 -1
- package/es/hooks/useRafState.js.map +1 -0
- package/es/hooks/useRefCache.js +12 -1
- package/es/hooks/useRefCache.js.map +1 -0
- package/es/hooks/useSafeSate.js +16 -1
- package/es/hooks/useSafeSate.js.map +1 -0
- package/es/hooks/useSize.js +39 -1
- package/es/hooks/useSize.js.map +1 -0
- package/es/hooks/useUnmountedRef.js +15 -1
- package/es/hooks/useUnmountedRef.js.map +1 -0
- package/es/index.js +64 -1
- package/es/index.js.map +1 -0
- package/es/store/Actions.js +51 -1
- package/es/store/Actions.js.map +1 -0
- package/es/store/annotation/actionCreators.js +450 -1
- package/es/store/annotation/actionCreators.js.map +1 -0
- package/es/store/annotation/map.js +22 -1
- package/es/store/annotation/map.js.map +1 -0
- package/es/store/annotation/reducer.js +657 -1
- package/es/store/annotation/reducer.js.map +1 -0
- package/es/store/annotation/selectors.js +11 -1
- package/es/store/annotation/selectors.js.map +1 -0
- package/es/store/ctx.js +9 -1
- package/es/store/ctx.js.map +1 -0
- package/es/store/imgAttribute/actionCreators.js +21 -1
- package/es/store/imgAttribute/actionCreators.js.map +1 -0
- package/es/store/imgAttribute/reducer.js +40 -1
- package/es/store/imgAttribute/reducer.js.map +1 -0
- package/es/store/index.js +13 -1
- package/es/store/index.js.map +1 -0
- package/es/store/toolStyle/actionCreators.js +17 -1
- package/es/store/toolStyle/actionCreators.js.map +1 -0
- package/es/store/toolStyle/reducer.js +50 -1
- package/es/store/toolStyle/reducer.js.map +1 -0
- package/es/utils/AnnotationDataUtils.js +165 -1
- package/es/utils/AnnotationDataUtils.js.map +1 -0
- package/es/utils/ConfigUtils.js +18 -1
- package/es/utils/ConfigUtils.js.map +1 -0
- package/es/utils/PageOperator.js +93 -1
- package/es/utils/PageOperator.js.map +1 -0
- package/es/utils/StepUtils.js +27 -1
- package/es/utils/StepUtils.js.map +1 -0
- package/es/utils/TextUtils.js +39 -1
- package/es/utils/TextUtils.js.map +1 -0
- package/es/utils/ToolStyleUtils.js +88 -1
- package/es/utils/ToolStyleUtils.js.map +1 -0
- package/es/utils/ToolUtils.js +17 -1
- package/es/utils/ToolUtils.js.map +1 -0
- package/es/utils/data.js +72 -1
- package/es/utils/data.js.map +1 -0
- package/es/utils/dom.js +20 -1
- package/es/utils/dom.js.map +1 -0
- package/es/utils/index.js +30 -1
- package/es/utils/index.js.map +1 -0
- package/es/views/MainView/annotationOperation/index.js +168 -1
- package/es/views/MainView/annotationOperation/index.js.map +1 -0
- package/es/views/MainView/annotationTips/index.js +26 -1
- package/es/views/MainView/annotationTips/index.js.map +1 -0
- package/es/views/MainView/index.js +116 -1
- package/es/views/MainView/index.js.map +1 -0
- package/es/views/MainView/sidebar/AnnotationText/index.js +41 -1
- package/es/views/MainView/sidebar/AnnotationText/index.js.map +1 -0
- package/es/views/MainView/sidebar/ClearIcon/index.js +31 -1
- package/es/views/MainView/sidebar/ClearIcon/index.js.map +1 -0
- package/es/views/MainView/sidebar/GeneralOperation/ActionsConfirm.js +95 -1
- package/es/views/MainView/sidebar/GeneralOperation/ActionsConfirm.js.map +1 -0
- package/es/views/MainView/sidebar/GeneralOperation/index.js +86 -1
- package/es/views/MainView/sidebar/GeneralOperation/index.js.map +1 -0
- package/es/views/MainView/sidebar/GeneralOperation/useOperationList.js +88 -1
- package/es/views/MainView/sidebar/GeneralOperation/useOperationList.js.map +1 -0
- package/es/views/MainView/sidebar/ImgAttributeInfo/index.js +128 -1
- package/es/views/MainView/sidebar/ImgAttributeInfo/index.js.map +1 -0
- package/es/views/MainView/sidebar/PointCloudToolSidebar/components/batchUpdateModal/index.js +122 -1
- package/es/views/MainView/sidebar/PointCloudToolSidebar/components/batchUpdateModal/index.js.map +1 -0
- package/es/views/MainView/sidebar/PointCloudToolSidebar/index.js +247 -1
- package/es/views/MainView/sidebar/PointCloudToolSidebar/index.js.map +1 -0
- package/es/views/MainView/sidebar/ScribbleSidebar/index.js +58 -1
- package/es/views/MainView/sidebar/ScribbleSidebar/index.js.map +1 -0
- package/es/views/MainView/sidebar/SwitchAttributeList/index.js +73 -1
- package/es/views/MainView/sidebar/SwitchAttributeList/index.js.map +1 -0
- package/es/views/MainView/sidebar/TagSidebar/index.js +178 -1
- package/es/views/MainView/sidebar/TagSidebar/index.js.map +1 -0
- package/es/views/MainView/sidebar/TextAreaFormat/index.js +106 -1
- package/es/views/MainView/sidebar/TextAreaFormat/index.js.map +1 -0
- package/es/views/MainView/sidebar/TextToolSidebar/index.js +225 -1
- package/es/views/MainView/sidebar/TextToolSidebar/index.js.map +1 -0
- package/es/views/MainView/sidebar/ToolIcons.js +78 -1
- package/es/views/MainView/sidebar/ToolIcons.js.map +1 -0
- package/es/views/MainView/sidebar/ToolStyle/index.js +156 -1
- package/es/views/MainView/sidebar/ToolStyle/index.js.map +1 -0
- package/es/views/MainView/sidebar/index.js +147 -1
- package/es/views/MainView/sidebar/index.js.map +1 -0
- package/es/views/MainView/toolFooter/AnnotatedAttributes/index.js +200 -1
- package/es/views/MainView/toolFooter/AnnotatedAttributes/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterPopover.js +48 -1
- package/es/views/MainView/toolFooter/FooterPopover.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/common/index.js +127 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/common/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/cuboid/index.js +24 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/cuboid/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/index.js +216 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/line/index.js +97 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/line/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/point/index.js +47 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/point/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/pointCloud/index.js +165 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/pointCloud/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/polygon/index.js +102 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/polygon/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/rectToolShortCutTable/index.js +61 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/rectToolShortCutTable/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/scribble/index.js +16 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/scribble/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/tag/index.js +20 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/tag/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/text/index.js +16 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/text/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/videoTag/index.js +22 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/videoTag/index.js.map +1 -0
- package/es/views/MainView/toolFooter/FooterTips/index.js +17 -1
- package/es/views/MainView/toolFooter/FooterTips/index.js.map +1 -0
- package/es/views/MainView/toolFooter/HiddenTips/index.js +39 -1
- package/es/views/MainView/toolFooter/HiddenTips/index.js.map +1 -0
- package/es/views/MainView/toolFooter/PageNumber/index.js +42 -1
- package/es/views/MainView/toolFooter/PageNumber/index.js.map +1 -0
- package/es/views/MainView/toolFooter/Pagination.js +82 -1
- package/es/views/MainView/toolFooter/Pagination.js.map +1 -0
- package/es/views/MainView/toolFooter/ZoomController/ZoomLevel/index.js +33 -1
- package/es/views/MainView/toolFooter/ZoomController/ZoomLevel/index.js.map +1 -0
- package/es/views/MainView/toolFooter/ZoomController/index.js +63 -1
- package/es/views/MainView/toolFooter/ZoomController/index.js.map +1 -0
- package/es/views/MainView/toolFooter/index.js +125 -1
- package/es/views/MainView/toolFooter/index.js.map +1 -0
- package/es/views/MainView/toolHeader/ExportData/index.js +38 -1
- package/es/views/MainView/toolHeader/ExportData/index.js.map +1 -0
- package/es/views/MainView/toolHeader/StepSwitch/index.js +41 -1
- package/es/views/MainView/toolHeader/StepSwitch/index.js.map +1 -0
- package/es/views/MainView/toolHeader/SwitchPattern/index.js +53 -0
- package/es/views/MainView/toolHeader/SwitchPattern/index.js.map +1 -0
- package/es/views/MainView/toolHeader/headerOption/index.js +145 -1
- package/es/views/MainView/toolHeader/headerOption/index.js.map +1 -0
- package/es/views/MainView/toolHeader/index.js +173 -1
- package/es/views/MainView/toolHeader/index.js.map +1 -0
- package/package.json +6 -5
- package/LICENSE +0 -203
|
@@ -1 +1,178 @@
|
|
|
1
|
-
import
|
|
1
|
+
import AttributeList from '../../../../components/attributeList/index.js';
|
|
2
|
+
import CheckboxList from '../../../../components/checkboxList/index.js';
|
|
3
|
+
import { CaretRightOutlined } from '@ant-design/icons';
|
|
4
|
+
import { Collapse, Tooltip, Badge } from 'antd/es';
|
|
5
|
+
import { cloneDeep } from 'lodash';
|
|
6
|
+
import React, { useState, useRef, useEffect, useCallback } from 'react';
|
|
7
|
+
import img$1 from '../../../../assets/annotation/common/icon_clearSmall.svg.js';
|
|
8
|
+
import img from '../../../../assets/annotation/common/icon_clearSmall_a.svg.js';
|
|
9
|
+
import { TagUtils } from '@labelbee/lb-annotation';
|
|
10
|
+
import { connect } from 'react-redux';
|
|
11
|
+
import { useTranslation } from 'react-i18next';
|
|
12
|
+
import { LabelBeeContext } from '../../../../store/ctx.js';
|
|
13
|
+
|
|
14
|
+
const {Panel} = Collapse;
|
|
15
|
+
const expandIconFuc = ({isActive}) => /* @__PURE__ */ React.createElement(CaretRightOutlined, {
|
|
16
|
+
rotate: isActive ? 90 : 0
|
|
17
|
+
});
|
|
18
|
+
const TagSidebar = ({toolInstance, imgIndex}) => {
|
|
19
|
+
const [expandKeyList, setExpandKeyList] = useState([]);
|
|
20
|
+
const sidebarRef = useRef(null);
|
|
21
|
+
const [, forceRender] = useState(0);
|
|
22
|
+
const [hoverDeleteIndex, setHoverDeleteIndex] = useState(-1);
|
|
23
|
+
const {t} = useTranslation();
|
|
24
|
+
useEffect(() => {
|
|
25
|
+
if (toolInstance) {
|
|
26
|
+
setExpandKeyList(toolInstance.config.inputList.map((v) => v.value));
|
|
27
|
+
toolInstance.singleOn("render", () => {
|
|
28
|
+
forceRender((s) => s + 1);
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
}, [toolInstance]);
|
|
32
|
+
useEffect(() => {
|
|
33
|
+
if (toolInstance) {
|
|
34
|
+
toolInstance.singleOn("expend", expendRender);
|
|
35
|
+
if (toolInstance.labelSelectedList.length === 1) {
|
|
36
|
+
let height2 = 0;
|
|
37
|
+
for (let i = 0; i < toolInstance.labelSelectedList[0]; i++) {
|
|
38
|
+
height2 += 46;
|
|
39
|
+
inputList[i] && expandKeyList[i] !== "" && inputList[i].subSelected.forEach((i2) => {
|
|
40
|
+
height2 += 40;
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
if (sidebarRef.current) {
|
|
44
|
+
sidebarRef.current.children[0].scrollTop = height2;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
});
|
|
49
|
+
useEffect(() => {
|
|
50
|
+
if (sidebarRef.current) {
|
|
51
|
+
sidebarRef.current.children[0].scrollTop = 0;
|
|
52
|
+
}
|
|
53
|
+
}, [imgIndex]);
|
|
54
|
+
const expendRender = () => {
|
|
55
|
+
var _a;
|
|
56
|
+
const index = toolInstance.labelSelectedList[0];
|
|
57
|
+
const value = (_a = inputList.filter((v, i) => i === index)[0]) == null ? void 0 : _a.value;
|
|
58
|
+
setExpendKeyList(index, value, true);
|
|
59
|
+
};
|
|
60
|
+
const setExpendKeyList = useCallback((index, value, expend) => {
|
|
61
|
+
const newKeyList = cloneDeep(expandKeyList);
|
|
62
|
+
if (newKeyList[index] === "" || expend === true) {
|
|
63
|
+
newKeyList[index] = value;
|
|
64
|
+
} else {
|
|
65
|
+
newKeyList[index] = "";
|
|
66
|
+
}
|
|
67
|
+
setExpandKeyList(newKeyList);
|
|
68
|
+
}, [expandKeyList]);
|
|
69
|
+
if (!toolInstance)
|
|
70
|
+
return null;
|
|
71
|
+
const {
|
|
72
|
+
labelSelectedList,
|
|
73
|
+
config: {inputList},
|
|
74
|
+
currentTagResult,
|
|
75
|
+
setLabel
|
|
76
|
+
} = toolInstance;
|
|
77
|
+
const selectedButton = (index) => {
|
|
78
|
+
if (labelSelectedList.length > 0 && labelSelectedList[0] === index) {
|
|
79
|
+
return /* @__PURE__ */ React.createElement("span", {
|
|
80
|
+
className: "keyDownIconActive"
|
|
81
|
+
}, index + 1);
|
|
82
|
+
}
|
|
83
|
+
return /* @__PURE__ */ React.createElement("span", {
|
|
84
|
+
className: "keyDownIcon"
|
|
85
|
+
}, index + 1);
|
|
86
|
+
};
|
|
87
|
+
const labelPanel = (labelInfoSet, basicIndex = -1) => {
|
|
88
|
+
if (!labelInfoSet) {
|
|
89
|
+
return null;
|
|
90
|
+
}
|
|
91
|
+
return labelInfoSet.map((info, index) => {
|
|
92
|
+
var _a, _b, _c, _d, _e;
|
|
93
|
+
if (info.subSelected) {
|
|
94
|
+
const isResult = TagUtils.judgeResultIsInInputList(info.value, (_a = currentTagResult == null ? void 0 : currentTagResult.result) == null ? void 0 : _a[info.value], inputList);
|
|
95
|
+
return /* @__PURE__ */ React.createElement(Collapse, {
|
|
96
|
+
bordered: false,
|
|
97
|
+
expandIcon: expandIconFuc,
|
|
98
|
+
key: `collapse_${index}_${basicIndex + 1}`,
|
|
99
|
+
onChange: () => setExpendKeyList(index, info.value),
|
|
100
|
+
activeKey: [expandKeyList[index]]
|
|
101
|
+
}, /* @__PURE__ */ React.createElement(Panel, {
|
|
102
|
+
header: /* @__PURE__ */ React.createElement("div", {
|
|
103
|
+
style: {
|
|
104
|
+
display: "flex",
|
|
105
|
+
justifyContent: "space-between",
|
|
106
|
+
alignItems: "center",
|
|
107
|
+
flex: 1
|
|
108
|
+
}
|
|
109
|
+
}, /* @__PURE__ */ React.createElement("span", null, info.key, /* @__PURE__ */ React.createElement(Tooltip, {
|
|
110
|
+
placement: "bottom",
|
|
111
|
+
title: t("ClearThisOption")
|
|
112
|
+
}, /* @__PURE__ */ React.createElement("img", {
|
|
113
|
+
style: {marginLeft: 5, cursor: "pointer"},
|
|
114
|
+
onClick: (e) => {
|
|
115
|
+
e.stopPropagation();
|
|
116
|
+
toolInstance.clearResult(true, info.value);
|
|
117
|
+
},
|
|
118
|
+
src: hoverDeleteIndex === index || isResult ? img : img$1,
|
|
119
|
+
onMouseEnter: () => {
|
|
120
|
+
setHoverDeleteIndex(index);
|
|
121
|
+
},
|
|
122
|
+
onMouseLeave: () => {
|
|
123
|
+
setHoverDeleteIndex(-1);
|
|
124
|
+
}
|
|
125
|
+
})), isResult && expandKeyList[index] === "" && /* @__PURE__ */ React.createElement(Badge, {
|
|
126
|
+
color: "#87d068"
|
|
127
|
+
})), (inputList == null ? void 0 : inputList.length) > 1 && selectedButton(index)),
|
|
128
|
+
key: info.value
|
|
129
|
+
}, /* @__PURE__ */ React.createElement("div", {
|
|
130
|
+
className: "level",
|
|
131
|
+
style: {
|
|
132
|
+
backgroundColor: labelSelectedList.length > 0 && labelSelectedList[0] === index ? "rgba(158, 158, 158, 0.18)" : ""
|
|
133
|
+
}
|
|
134
|
+
}, labelPanel(info.subSelected, index))));
|
|
135
|
+
}
|
|
136
|
+
const key = (inputList == null ? void 0 : inputList[basicIndex]) ? inputList == null ? void 0 : inputList[basicIndex].value : 0;
|
|
137
|
+
const selectedAttribute = ((_d = (_c = (_b = currentTagResult == null ? void 0 : currentTagResult.result) == null ? void 0 : _b[key]) == null ? void 0 : _c.split(";")) == null ? void 0 : _d.indexOf(info.value)) > -1 ? info.value : "";
|
|
138
|
+
if (((_e = inputList == null ? void 0 : inputList[basicIndex]) == null ? void 0 : _e.isMulti) === true) {
|
|
139
|
+
return /* @__PURE__ */ React.createElement("div", {
|
|
140
|
+
className: "singleBar",
|
|
141
|
+
key: `${key}_${basicIndex}_${index}`
|
|
142
|
+
}, /* @__PURE__ */ React.createElement(CheckboxList, {
|
|
143
|
+
attributeChanged: () => setLabel(basicIndex, index),
|
|
144
|
+
selectedAttribute: [selectedAttribute],
|
|
145
|
+
list: [{value: info.value, label: info.key}],
|
|
146
|
+
num: index + 1
|
|
147
|
+
}));
|
|
148
|
+
}
|
|
149
|
+
return /* @__PURE__ */ React.createElement("div", {
|
|
150
|
+
className: "singleBar",
|
|
151
|
+
key: `${key}_${basicIndex}_${index}`
|
|
152
|
+
}, /* @__PURE__ */ React.createElement(AttributeList, {
|
|
153
|
+
forbidColor: true,
|
|
154
|
+
attributeChanged: () => setLabel(basicIndex, index),
|
|
155
|
+
selectedAttribute,
|
|
156
|
+
list: [{value: info.value, label: info.key}],
|
|
157
|
+
num: index + 1
|
|
158
|
+
}));
|
|
159
|
+
});
|
|
160
|
+
};
|
|
161
|
+
const height = window.innerHeight - 61 - 80;
|
|
162
|
+
return /* @__PURE__ */ React.createElement("div", {
|
|
163
|
+
className: "tagOperationMenu",
|
|
164
|
+
ref: sidebarRef
|
|
165
|
+
}, (inputList == null ? void 0 : inputList.length) === 0 ? /* @__PURE__ */ React.createElement("div", {
|
|
166
|
+
style: {padding: 20, textAlign: "center"}
|
|
167
|
+
}, t("NoConfiguration")) : /* @__PURE__ */ React.createElement("div", {
|
|
168
|
+
className: "main",
|
|
169
|
+
style: {height}
|
|
170
|
+
}, labelPanel(inputList)));
|
|
171
|
+
};
|
|
172
|
+
function mapStateToProps(state) {
|
|
173
|
+
return {toolInstance: state.annotation.toolInstance, imgIndex: state.annotation.imgIndex};
|
|
174
|
+
}
|
|
175
|
+
var TagSidebar$1 = connect(mapStateToProps, null, null, {context: LabelBeeContext})(TagSidebar);
|
|
176
|
+
|
|
177
|
+
export { TagSidebar$1 as default, expandIconFuc };
|
|
178
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../../src/views/MainView/sidebar/TagSidebar/index.tsx"],"sourcesContent":["import RadioList from '@/components/attributeList';\nimport CheckBoxList from '@/components/checkboxList';\nimport { CaretRightOutlined } from '@ant-design/icons';\nimport { Badge, Collapse, Tooltip } from 'antd/es';\nimport { cloneDeep } from 'lodash';\nimport React, { useCallback, useEffect, useRef, useState } from 'react';\nimport clearSmall from '@/assets/annotation/common/icon_clearSmall.svg';\nimport clearSmallA from '@/assets/annotation/common/icon_clearSmall_a.svg';\nimport { TagOperation, TagUtils } from '@labelbee/lb-annotation';\nimport { connect } from 'react-redux';\nimport { AppState } from '@/store';\nimport { IInputList } from '@/types/main';\nimport { useTranslation } from 'react-i18next';\nimport { LabelBeeContext } from '@/store/ctx';\n\ninterface IProps {\n imgIndex: number;\n toolInstance: TagOperation;\n}\n\nconst { Panel } = Collapse;\n\nexport const expandIconFuc = ({ isActive }: any) => (\n <CaretRightOutlined rotate={isActive ? 90 : 0} />\n);\n\nconst TagSidebar: React.FC<IProps> = ({ toolInstance, imgIndex }) => {\n const [expandKeyList, setExpandKeyList] = useState<string[]>([]);\n\n const sidebarRef = useRef<HTMLDivElement>(null);\n const [, forceRender] = useState<number>(0);\n const [hoverDeleteIndex, setHoverDeleteIndex] = useState(-1);\n const { t } = useTranslation();\n\n useEffect(() => {\n if (toolInstance) {\n // 用于配置的初始化\n setExpandKeyList(toolInstance.config.inputList.map((v: IInputList) => v.value));\n\n // 进行实时渲染\n toolInstance.singleOn('render', () => {\n forceRender((s) => s + 1);\n });\n }\n }, [toolInstance]);\n\n useEffect(() => {\n if (toolInstance) {\n // 该写法会不断的重复绑定,后续写法上可以更改(如果将 singleOn 改为 on 会有很大问题)\n toolInstance.singleOn('expend', expendRender);\n\n if (toolInstance.labelSelectedList.length === 1) {\n let height = 0;\n for (let i = 0; i < toolInstance.labelSelectedList[0]; i++) {\n height += 46;\n inputList[i] &&\n expandKeyList[i] !== '' &&\n inputList[i].subSelected.forEach((i: any) => {\n height += 40;\n });\n }\n if (sidebarRef.current) {\n sidebarRef.current.children[0].scrollTop = height;\n }\n }\n }\n });\n\n useEffect(() => {\n // 翻页侧边栏跳到最上\n if (sidebarRef.current) {\n sidebarRef.current.children[0].scrollTop = 0;\n }\n }, [imgIndex]);\n\n const expendRender = () => {\n const index = toolInstance.labelSelectedList[0];\n const value = inputList.filter((v: IInputList, i: number) => i === index)[0]?.value;\n setExpendKeyList(index, value, true);\n };\n\n const setExpendKeyList = useCallback(\n (index: number, value: string, expend?: boolean) => {\n const newKeyList = cloneDeep(expandKeyList);\n if (newKeyList[index] === '' || expend === true) {\n newKeyList[index] = value;\n } else {\n newKeyList[index] = '';\n }\n setExpandKeyList(newKeyList);\n },\n [expandKeyList],\n );\n\n if (!toolInstance) return null;\n\n const {\n labelSelectedList,\n config: { inputList },\n currentTagResult,\n setLabel,\n } = toolInstance;\n\n const selectedButton = (index: number) => {\n if (labelSelectedList.length > 0 && labelSelectedList[0] === index) {\n return <span className='keyDownIconActive'>{index + 1}</span>;\n }\n return <span className='keyDownIcon'>{index + 1}</span>;\n };\n\n // basicIndex 到底是那一层\n const labelPanel = (labelInfoSet: IInputList[], basicIndex = -1) => {\n if (!labelInfoSet) {\n return null;\n }\n\n return labelInfoSet.map((info: IInputList, index: number) => {\n if (info.subSelected) {\n // 判断是否有数据\n const isResult = TagUtils.judgeResultIsInInputList(\n info.value,\n currentTagResult?.result?.[info.value],\n inputList,\n );\n\n return (\n <Collapse\n bordered={false}\n expandIcon={expandIconFuc}\n key={`collapse_${index}_${basicIndex + 1}`}\n onChange={() => setExpendKeyList(index, info.value)}\n activeKey={[expandKeyList[index]]}\n >\n <Panel\n header={\n <div\n style={{\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'center',\n flex: 1,\n }}\n >\n <span>\n {info.key}\n <Tooltip placement='bottom' title={t('ClearThisOption')}>\n <img\n style={{ marginLeft: 5, cursor: 'pointer' }}\n onClick={(e) => {\n e.stopPropagation();\n toolInstance.clearResult(true, info.value);\n }}\n src={hoverDeleteIndex === index || isResult ? clearSmallA : clearSmall}\n onMouseEnter={() => {\n setHoverDeleteIndex(index);\n }}\n onMouseLeave={() => {\n setHoverDeleteIndex(-1);\n }}\n />\n </Tooltip>\n {isResult && expandKeyList[index] === '' && <Badge color='#87d068' />}\n </span>\n\n {inputList?.length > 1 && selectedButton(index)}\n </div>\n }\n key={info.value}\n >\n <div\n className='level'\n style={{\n backgroundColor:\n labelSelectedList.length > 0 && labelSelectedList[0] === index\n ? 'rgba(158, 158, 158, 0.18)'\n : '',\n }}\n >\n {labelPanel(info.subSelected, index)}\n </div>\n </Panel>\n </Collapse>\n );\n }\n const key = inputList?.[basicIndex] ? inputList?.[basicIndex].value : 0;\n const selectedAttribute =\n currentTagResult?.result?.[key]?.split(';')?.indexOf(info.value) > -1 ? info.value : '';\n\n if (inputList?.[basicIndex]?.isMulti === true) {\n return (\n <div className='singleBar' key={`${key}_${basicIndex}_${index}`}>\n <CheckBoxList\n attributeChanged={() => setLabel(basicIndex, index)}\n selectedAttribute={[selectedAttribute]}\n list={[{ value: info.value, label: info.key }]}\n num={index + 1}\n />\n </div>\n );\n }\n return (\n <div className='singleBar' key={`${key}_${basicIndex}_${index}`}>\n <RadioList\n forbidColor\n attributeChanged={() => setLabel(basicIndex, index)}\n selectedAttribute={selectedAttribute}\n list={[{ value: info.value, label: info.key }]}\n num={index + 1}\n />\n </div>\n );\n });\n };\n const height = window.innerHeight - 61 - 80;\n\n return (\n <div className='tagOperationMenu' ref={sidebarRef}>\n {inputList?.length === 0 ? (\n <div style={{ padding: 20, textAlign: 'center' }}>{t('NoConfiguration')}</div>\n ) : (\n <div className='main' style={{ height }}>\n {labelPanel(inputList)}\n </div>\n )}\n </div>\n );\n};\n\nfunction mapStateToProps(state: AppState) {\n return { toolInstance: state.annotation.toolInstance, imgIndex: state.annotation.imgIndex };\n}\n\nexport default connect(mapStateToProps, null, null, { context: LabelBeeContext })(TagSidebar);\n"],"names":["clearSmallA","clearSmall","CheckBoxList","RadioList"],"mappings":";;;;;;;;;;;;;AAoBA,MAAM,CAAE,KAAU,CAAA,GAAA,QAAA,CAAA;AAEX,MAAM,aAAgB,GAAA,CAAC,CAAE,QAAA,CAAA,yCAC7B,kBAAD,EAAA;AAAA,EAAoB,MAAA,EAAQ,WAAW,EAAK,GAAA,CAAA;AAAA,CAAA,EAAA;AAG9C,MAAM,UAA+B,GAAA,CAAC,CAAE,YAAA,EAAc,QAAe,CAAA,KAAA;AACnE,EAAM,MAAA,CAAC,aAAe,EAAA,gBAAA,CAAA,GAAoB,QAAmB,CAAA,EAAA,CAAA,CAAA;AAE7D,EAAA,MAAM,aAAa,MAAuB,CAAA,IAAA,CAAA,CAAA;AAC1C,EAAM,MAAA,GAAG,WAAA,CAAA,GAAe,QAAiB,CAAA,CAAA,CAAA,CAAA;AACzC,EAAM,MAAA,CAAC,gBAAkB,EAAA,mBAAA,CAAA,GAAuB,QAAS,CAAA,CAAA,CAAA,CAAA,CAAA;AACzD,EAAA,MAAM,CAAE,CAA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AC,KAAD,EAAA;AAAA,IAAK,KAAO,EAAA,CAAE,OAAS,EAAA,EAAA,EAAI,SAAW,EAAA,QAAA,CAAA;AAAA,GAAa,EAAA,CAAA,CAAE,iBAErD,CAAA,CAAA,mBAAA,KAAA,CAAA,aAAA,CAAC,KAAD,EAAA;AAAA,IAAK,SAAU,EAAA,MAAA;AAAA,IAAO,OAAO,CAAE,MAAA,CAAA;AAAA,GAAA,EAC5B,UAAW,CAAA,SAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CAAA,CAAA;AAOtB,SAAA,eAAA,CAAyB,KAAiB,EAAA;AACxC,EAAA,OAAO,CAAE,YAAc,EAAA,KAAA,CAAM,WAAW,YAAc,EAAA,QAAA,EAAU,MAAM,UAAW,CAAA,QAAA,CAAA,CAAA;AAAA,CAAA;AAGnF,mBAAe,QAAQ,eAAiB,EAAA,IAAA,EAAM,IAAM,EAAA,CAAE,SAAS,eAAmB,CAAA,CAAA,CAAA,UAAA,CAAA;;;;"}
|
|
@@ -1 +1,106 @@
|
|
|
1
|
-
import{TEXT_ATTRIBUTE_MAX_LENGTH
|
|
1
|
+
import { TEXT_ATTRIBUTE_MAX_LENGTH } from '../../../../data/enums/ToolType.js';
|
|
2
|
+
import { TextUtils } from '../../../../utils/TextUtils.js';
|
|
3
|
+
import { Tooltip, message, Input } from 'antd/es';
|
|
4
|
+
import React, { useState, useEffect } from 'react';
|
|
5
|
+
import img from '../../../../assets/annotation/common/icon_clearSmall_a.svg.js';
|
|
6
|
+
import img$1 from '../../../../assets/annotation/common/icon_clearSmall.svg.js';
|
|
7
|
+
import { classnames } from '../../../../utils/index.js';
|
|
8
|
+
import { useTranslation } from 'react-i18next';
|
|
9
|
+
|
|
10
|
+
const TextAreaFormat = (props) => {
|
|
11
|
+
const {t} = useTranslation();
|
|
12
|
+
const {onChange, textValue, checkString, textCheckType} = props;
|
|
13
|
+
const [textLength, setTextLength] = useState(0);
|
|
14
|
+
const [error, setError] = useState(false);
|
|
15
|
+
const [onFocus, setOnFocus] = useState(false);
|
|
16
|
+
const [hoverDelete, setHoverDelete] = useState(false);
|
|
17
|
+
const clearIcon = /* @__PURE__ */ React.createElement("a", null, /* @__PURE__ */ React.createElement(Tooltip, {
|
|
18
|
+
placement: "bottom",
|
|
19
|
+
title: t("EmptyTextInput")
|
|
20
|
+
}, /* @__PURE__ */ React.createElement("img", {
|
|
21
|
+
onMouseEnter: () => setHoverDelete(true),
|
|
22
|
+
onMouseLeave: () => setHoverDelete(false),
|
|
23
|
+
style: {marginLeft: 6},
|
|
24
|
+
src: hoverDelete ? img : img$1,
|
|
25
|
+
onClick: (e) => {
|
|
26
|
+
e.stopPropagation();
|
|
27
|
+
onChange("");
|
|
28
|
+
}
|
|
29
|
+
})));
|
|
30
|
+
const keyDown = (e) => {
|
|
31
|
+
e.stopPropagation();
|
|
32
|
+
};
|
|
33
|
+
useEffect(() => {
|
|
34
|
+
if (textValue) {
|
|
35
|
+
setTextLength(textValue.length);
|
|
36
|
+
}
|
|
37
|
+
}, []);
|
|
38
|
+
useEffect(() => {
|
|
39
|
+
var _a;
|
|
40
|
+
if (textValue === void 0 || textValue === "") {
|
|
41
|
+
setError(false);
|
|
42
|
+
} else {
|
|
43
|
+
try {
|
|
44
|
+
textValue && setError(!new RegExp(checkString).test(textValue));
|
|
45
|
+
} catch (error2) {
|
|
46
|
+
setError(true);
|
|
47
|
+
message.destroy();
|
|
48
|
+
message.error(t("RegularExpIncorrectly"));
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
setTextLength((_a = textValue == null ? void 0 : textValue.length) != null ? _a : 0);
|
|
52
|
+
}, [textValue]);
|
|
53
|
+
const checkText = (e) => {
|
|
54
|
+
if (error || !new RegExp(checkString).test(e.target.value)) {
|
|
55
|
+
onChange("");
|
|
56
|
+
message.error(TextUtils.getErrorNotice(textCheckType));
|
|
57
|
+
return true;
|
|
58
|
+
}
|
|
59
|
+
onChange(e.target.value, true);
|
|
60
|
+
};
|
|
61
|
+
return /* @__PURE__ */ React.createElement("div", {
|
|
62
|
+
className: "textInputContainer"
|
|
63
|
+
}, /* @__PURE__ */ React.createElement("div", {
|
|
64
|
+
className: "label"
|
|
65
|
+
}, t("TextInput"), clearIcon), /* @__PURE__ */ React.createElement("div", {
|
|
66
|
+
className: classnames({
|
|
67
|
+
textareaContainer: true,
|
|
68
|
+
focus: onFocus
|
|
69
|
+
})
|
|
70
|
+
}, /* @__PURE__ */ React.createElement("div", {
|
|
71
|
+
className: classnames({
|
|
72
|
+
toolTextAreaBox: true,
|
|
73
|
+
toolTextAreaBoxFocus: onFocus
|
|
74
|
+
})
|
|
75
|
+
}, /* @__PURE__ */ React.createElement(Input.TextArea, {
|
|
76
|
+
style: {resize: "none", height: 120, wordBreak: "break-all"},
|
|
77
|
+
maxLength: TEXT_ATTRIBUTE_MAX_LENGTH,
|
|
78
|
+
onKeyDownCapture: (e) => {
|
|
79
|
+
e.stopPropagation();
|
|
80
|
+
},
|
|
81
|
+
onKeyUpCapture: (e) => {
|
|
82
|
+
e.stopPropagation();
|
|
83
|
+
},
|
|
84
|
+
onChange: (e) => {
|
|
85
|
+
onChange(e.target.value);
|
|
86
|
+
setTextLength(e.target.value.length);
|
|
87
|
+
},
|
|
88
|
+
onFocus: (e) => setOnFocus(true),
|
|
89
|
+
onBlur: (e) => {
|
|
90
|
+
checkText(e);
|
|
91
|
+
setOnFocus(false);
|
|
92
|
+
},
|
|
93
|
+
value: textValue,
|
|
94
|
+
onKeyDown: keyDown,
|
|
95
|
+
className: error ? "warning" : ""
|
|
96
|
+
}), /* @__PURE__ */ React.createElement("div", {
|
|
97
|
+
className: "textAreaFooter"
|
|
98
|
+
}, /* @__PURE__ */ React.createElement("span", {
|
|
99
|
+
className: "wordCount"
|
|
100
|
+
}, /* @__PURE__ */ React.createElement("span", {
|
|
101
|
+
className: textLength > TEXT_ATTRIBUTE_MAX_LENGTH || error ? "warning" : ""
|
|
102
|
+
}, textLength), "/", /* @__PURE__ */ React.createElement("span", null, TEXT_ATTRIBUTE_MAX_LENGTH))))));
|
|
103
|
+
};
|
|
104
|
+
|
|
105
|
+
export { TextAreaFormat as default };
|
|
106
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../../src/views/MainView/sidebar/TextAreaFormat/index.tsx"],"sourcesContent":["import { TEXT_ATTRIBUTE_MAX_LENGTH } from '@/data/enums/ToolType';\nimport { TextUtils } from '@/utils/TextUtils';\nimport { Input, message, Tooltip } from 'antd/es';\nimport React, { FocusEvent, useEffect, useState } from 'react';\nimport IconClearSmallA from '@/assets/annotation/common/icon_clearSmall_a.svg';\nimport IconClearSmall from '@/assets/annotation/common/icon_clearSmall.svg';\nimport { classnames } from '@/utils';\nimport { useTranslation } from 'react-i18next';\n\ninterface IProps {\n onChange: (value: string, isSubmit?: boolean) => void;\n textValue: string | undefined;\n checkString: string;\n textCheckType: number;\n}\n\nconst TextAreaFormat = (props: IProps) => {\n const { t } = useTranslation();\n\n const { onChange, textValue, checkString, textCheckType } = props;\n const [textLength, setTextLength] = useState<number>(0);\n const [error, setError] = useState<boolean>(false);\n const [onFocus, setOnFocus] = useState<boolean>(false);\n const [hoverDelete, setHoverDelete] = useState<boolean>(false);\n\n const clearIcon = (\n <a>\n <Tooltip placement='bottom' title={t('EmptyTextInput')}>\n <img\n onMouseEnter={() => setHoverDelete(true)}\n onMouseLeave={() => setHoverDelete(false)}\n style={{ marginLeft: 6 }}\n src={hoverDelete ? IconClearSmallA : IconClearSmall}\n onClick={(e) => {\n e.stopPropagation();\n onChange('');\n }}\n />\n </Tooltip>\n </a>\n );\n\n const keyDown = (e: React.KeyboardEvent) => {\n e.stopPropagation();\n };\n\n useEffect(() => {\n if (textValue) {\n setTextLength(textValue.length);\n }\n }, []);\n\n useEffect(() => {\n if (textValue === undefined || textValue === '') {\n setError(false);\n } else {\n try {\n textValue && setError(!new RegExp(checkString).test(textValue));\n } catch (error) {\n setError(true);\n message.destroy();\n message.error(t('RegularExpIncorrectly'));\n }\n }\n setTextLength(textValue?.length ?? 0);\n }, [textValue]);\n\n const checkText = (e: FocusEvent<HTMLTextAreaElement>) => {\n if (error || !new RegExp(checkString).test(e.target.value)) {\n onChange('');\n message.error(TextUtils.getErrorNotice(textCheckType));\n return true;\n }\n onChange(e.target.value, true); // 失焦的时候直接进行数据的提交\n };\n\n return (\n <div className='textInputContainer'>\n <div className='label'>\n {t('TextInput')}\n {clearIcon}\n </div>\n <div\n className={classnames({\n textareaContainer: true,\n focus: onFocus,\n })}\n >\n <div\n className={classnames({\n toolTextAreaBox: true,\n toolTextAreaBoxFocus: onFocus,\n })}\n >\n <Input.TextArea\n style={{ resize: 'none', height: 120, wordBreak: 'break-all' }}\n maxLength={TEXT_ATTRIBUTE_MAX_LENGTH}\n onKeyDownCapture={(e) => {\n e.stopPropagation();\n }}\n onKeyUpCapture={(e) => {\n e.stopPropagation();\n }}\n onChange={(e) => {\n onChange(e.target.value);\n setTextLength(e.target.value.length);\n }}\n onFocus={(e) => setOnFocus(true)}\n onBlur={(e) => {\n checkText(e);\n setOnFocus(false);\n }}\n value={textValue}\n onKeyDown={keyDown}\n className={error ? 'warning' : ''}\n />\n <div className='textAreaFooter'>\n <span className='wordCount'>\n <span className={textLength > TEXT_ATTRIBUTE_MAX_LENGTH || error ? 'warning' : ''}>\n {textLength}\n </span>\n /<span>{TEXT_ATTRIBUTE_MAX_LENGTH}</span>\n </span>\n </div>\n </div>\n </div>\n </div>\n );\n};\n\nexport default TextAreaFormat;\n"],"names":["IconClearSmallA","IconClearSmall"],"mappings":";;;;;;;;;AAgBM,MAAA,cAAA,GAAiB,CAAC,KAAkB,KAAA;AACxC,EAAA,MAAM,CAAE,CAAM,CAAA,GAAA,cAAA,EAAA,CAAA;AAEd,EAAA,MAAM,CAAE,QAAA,EAAU,SAAW,EAAA,WAAA,EAAa,aAAkB,CAAA,GAAA,KAAA,CAAA;AAC5D,EAAM,MAAA,CAAC,UAAY,EAAA,a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AAA,IAAK,SAAU,EAAA,gBAAA;AAAA,GAAA,sCACZ,MAAD,EAAA;AAAA,IAAM,SAAU,EAAA,WAAA;AAAA,GAAA,sCACb,MAAD,EAAA;AAAA,IAAM,SAAW,EAAA,UAAA,GAAa,yBAA6B,IAAA,KAAA,GAAQ,SAAY,GAAA,EAAA;AAAA,GAAA,EAC5E,UACI,CAAA,EAAA,GAAA,kBACL,KAAA,CAAA,aAAA,CAAA,MAAA,EAAD,IAAO,EAAA,yBAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA;;;;"}
|
|
@@ -1 +1,225 @@
|
|
|
1
|
-
import
|
|
1
|
+
import React, { useState, useEffect, useRef } from 'react';
|
|
2
|
+
import { connect } from 'react-redux';
|
|
3
|
+
import { cloneDeep } from 'lodash';
|
|
4
|
+
import { classnames } from '../../../../utils/index.js';
|
|
5
|
+
import { Input } from 'antd/es';
|
|
6
|
+
import { cKeyCode } from '@labelbee/lb-annotation';
|
|
7
|
+
import { PageForward } from '../../../../store/annotation/actionCreators.js';
|
|
8
|
+
import { ConfigUtils } from '../../../../utils/ConfigUtils.js';
|
|
9
|
+
import { useTranslation } from 'react-i18next';
|
|
10
|
+
import { LabelBeeContext } from '../../../../store/ctx.js';
|
|
11
|
+
|
|
12
|
+
var __defProp = Object.defineProperty;
|
|
13
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
14
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
15
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
16
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, {enumerable: true, configurable: true, writable: true, value}) : obj[key] = value;
|
|
17
|
+
var __spreadValues = (a, b) => {
|
|
18
|
+
for (var prop in b || (b = {}))
|
|
19
|
+
if (__hasOwnProp.call(b, prop))
|
|
20
|
+
__defNormalProp(a, prop, b[prop]);
|
|
21
|
+
if (__getOwnPropSymbols)
|
|
22
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
23
|
+
if (__propIsEnum.call(b, prop))
|
|
24
|
+
__defNormalProp(a, prop, b[prop]);
|
|
25
|
+
}
|
|
26
|
+
return a;
|
|
27
|
+
};
|
|
28
|
+
const EKeyCode = cKeyCode.default;
|
|
29
|
+
const syntheticEventStopPagination = (e) => {
|
|
30
|
+
e.stopPropagation();
|
|
31
|
+
e.nativeEvent.stopPropagation();
|
|
32
|
+
e.nativeEvent.stopImmediatePropagation();
|
|
33
|
+
};
|
|
34
|
+
const TextareaWithFooter = (props) => {
|
|
35
|
+
const {textareaProps, footer} = props;
|
|
36
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Input.TextArea, __spreadValues({
|
|
37
|
+
bordered: false,
|
|
38
|
+
rows: 6,
|
|
39
|
+
onKeyDown: syntheticEventStopPagination,
|
|
40
|
+
onKeyUp: syntheticEventStopPagination
|
|
41
|
+
}, textareaProps)), /* @__PURE__ */ React.createElement("div", {
|
|
42
|
+
className: classnames({
|
|
43
|
+
textAreaLength: true
|
|
44
|
+
})
|
|
45
|
+
}, footer));
|
|
46
|
+
};
|
|
47
|
+
const SingleTextInput = (props) => {
|
|
48
|
+
var _a;
|
|
49
|
+
const ref = useRef(null);
|
|
50
|
+
const [textAreaFocus, setTextAreaFocus] = useState(false);
|
|
51
|
+
const [invalid, setInvalid] = useState(false);
|
|
52
|
+
const {t} = useTranslation();
|
|
53
|
+
const {disabled, config, result, updateText, index, switchToNextTextarea, hasMultiple, onNext} = props;
|
|
54
|
+
const {maxLength} = config;
|
|
55
|
+
const value = result ? result[config.key] : "";
|
|
56
|
+
const textLength = (_a = value == null ? void 0 : value.length) != null ? _a : 0;
|
|
57
|
+
const updateTextWithKey = (newVal) => {
|
|
58
|
+
if (updateText) {
|
|
59
|
+
updateText(newVal, config.key);
|
|
60
|
+
if (config.required) {
|
|
61
|
+
setInvalid(!newVal);
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
};
|
|
65
|
+
const tabToSwitchEnabled = hasMultiple && switchToNextTextarea;
|
|
66
|
+
const textareaProps = {
|
|
67
|
+
id: `textInput-${index}`,
|
|
68
|
+
ref,
|
|
69
|
+
disabled,
|
|
70
|
+
value,
|
|
71
|
+
maxLength,
|
|
72
|
+
autoSize: {minRows: 2, maxRows: 6},
|
|
73
|
+
onChange: (e) => {
|
|
74
|
+
const value2 = e.target.value;
|
|
75
|
+
updateTextWithKey(value2);
|
|
76
|
+
},
|
|
77
|
+
onFocus: () => {
|
|
78
|
+
setTextAreaFocus(true);
|
|
79
|
+
},
|
|
80
|
+
onBlur: (e) => {
|
|
81
|
+
setTextAreaFocus(false);
|
|
82
|
+
if (config.required) {
|
|
83
|
+
setInvalid(!e.target.value);
|
|
84
|
+
}
|
|
85
|
+
},
|
|
86
|
+
style: {
|
|
87
|
+
resize: "none",
|
|
88
|
+
wordBreak: "break-all"
|
|
89
|
+
},
|
|
90
|
+
onKeyDownCapture: (e) => {
|
|
91
|
+
if (e.ctrlKey && e.keyCode === EKeyCode.Enter) {
|
|
92
|
+
if (onNext) {
|
|
93
|
+
onNext();
|
|
94
|
+
}
|
|
95
|
+
e.preventDefault();
|
|
96
|
+
}
|
|
97
|
+
if (e.keyCode === EKeyCode.Tab && tabToSwitchEnabled) {
|
|
98
|
+
e.preventDefault();
|
|
99
|
+
e.nativeEvent.stopImmediatePropagation();
|
|
100
|
+
switchToNextTextarea(index);
|
|
101
|
+
}
|
|
102
|
+
e.nativeEvent.stopPropagation();
|
|
103
|
+
}
|
|
104
|
+
};
|
|
105
|
+
const TextareaFooter = /* @__PURE__ */ React.createElement("div", {
|
|
106
|
+
className: "textAreaFooter"
|
|
107
|
+
}, /* @__PURE__ */ React.createElement("div", {
|
|
108
|
+
className: "hotkeyTip"
|
|
109
|
+
}, tabToSwitchEnabled && /* @__PURE__ */ React.createElement("span", null, `[${t("Switch")}]Tab`), /* @__PURE__ */ React.createElement("span", null, `[${t("TurnPage")}]Ctrl+Enter`)), /* @__PURE__ */ React.createElement("div", {
|
|
110
|
+
className: "wordCount"
|
|
111
|
+
}, /* @__PURE__ */ React.createElement("span", {
|
|
112
|
+
className: textLength >= maxLength ? "warning" : ""
|
|
113
|
+
}, textLength), "/", /* @__PURE__ */ React.createElement("span", null, maxLength)));
|
|
114
|
+
useEffect(() => {
|
|
115
|
+
if (disabled) {
|
|
116
|
+
setTextAreaFocus(false);
|
|
117
|
+
}
|
|
118
|
+
}, [disabled]);
|
|
119
|
+
return /* @__PURE__ */ React.createElement("div", {
|
|
120
|
+
className: "textField"
|
|
121
|
+
}, /* @__PURE__ */ React.createElement("div", {
|
|
122
|
+
className: "label"
|
|
123
|
+
}, /* @__PURE__ */ React.createElement("span", {
|
|
124
|
+
className: classnames({required: config.required})
|
|
125
|
+
}, config.label), /* @__PURE__ */ React.createElement("i", {
|
|
126
|
+
className: classnames({clearText: true, disabled}),
|
|
127
|
+
onClick: () => {
|
|
128
|
+
if (disabled) {
|
|
129
|
+
return;
|
|
130
|
+
}
|
|
131
|
+
updateTextWithKey("");
|
|
132
|
+
}
|
|
133
|
+
})), /* @__PURE__ */ React.createElement("div", {
|
|
134
|
+
className: classnames({
|
|
135
|
+
disabled,
|
|
136
|
+
"textarea-outline": true,
|
|
137
|
+
"ant-input-focused": textAreaFocus,
|
|
138
|
+
textareaContainer: true,
|
|
139
|
+
focus: textAreaFocus,
|
|
140
|
+
invalid
|
|
141
|
+
})
|
|
142
|
+
}, /* @__PURE__ */ React.createElement(TextareaWithFooter, {
|
|
143
|
+
footer: TextareaFooter,
|
|
144
|
+
textareaProps
|
|
145
|
+
})));
|
|
146
|
+
};
|
|
147
|
+
const TextToolSidebar = ({
|
|
148
|
+
toolInstance,
|
|
149
|
+
imgIndex,
|
|
150
|
+
dispatch,
|
|
151
|
+
triggerEventAfterIndexChanged,
|
|
152
|
+
step,
|
|
153
|
+
stepList,
|
|
154
|
+
basicResultList
|
|
155
|
+
}) => {
|
|
156
|
+
var _a, _b;
|
|
157
|
+
const [configList, setConfigList] = useState([]);
|
|
158
|
+
const [focusIndex, setFocusIndex] = useState(0);
|
|
159
|
+
const [, forceRender] = useState(0);
|
|
160
|
+
const switchToNextTextarea = (currentIndex) => {
|
|
161
|
+
const nextIndex = (currentIndex + 1) % configList.length;
|
|
162
|
+
textareaFocus(nextIndex);
|
|
163
|
+
};
|
|
164
|
+
const textareaFocus = (index) => {
|
|
165
|
+
setTimeout(() => {
|
|
166
|
+
const textarea = document.getElementById(`textInput-${index}`);
|
|
167
|
+
if (textarea) {
|
|
168
|
+
setFocusIndex(index);
|
|
169
|
+
textarea.focus();
|
|
170
|
+
textarea.select();
|
|
171
|
+
textarea.scrollIntoView({behavior: "smooth", block: "center"});
|
|
172
|
+
}
|
|
173
|
+
});
|
|
174
|
+
};
|
|
175
|
+
useEffect(() => {
|
|
176
|
+
if (toolInstance) {
|
|
177
|
+
setConfigList(cloneDeep(toolInstance.config.configList));
|
|
178
|
+
toolInstance.singleOn("valueUpdated", () => {
|
|
179
|
+
forceRender((s) => s + 1);
|
|
180
|
+
});
|
|
181
|
+
}
|
|
182
|
+
}, [toolInstance]);
|
|
183
|
+
const updateText = (v, k) => {
|
|
184
|
+
toolInstance.updateTextValue(k, v);
|
|
185
|
+
};
|
|
186
|
+
useEffect(() => {
|
|
187
|
+
if (imgIndex > -1 && triggerEventAfterIndexChanged) {
|
|
188
|
+
textareaFocus(0);
|
|
189
|
+
}
|
|
190
|
+
}, [imgIndex]);
|
|
191
|
+
const result = (_b = (_a = toolInstance.textList[0]) == null ? void 0 : _a.value) != null ? _b : {};
|
|
192
|
+
const onNext = () => {
|
|
193
|
+
dispatch(PageForward(true));
|
|
194
|
+
};
|
|
195
|
+
const stepConfig = ConfigUtils.getStepConfig(stepList, step);
|
|
196
|
+
const disabled = stepConfig.dataSourceStep > 0 && basicResultList.length === 0;
|
|
197
|
+
return /* @__PURE__ */ React.createElement("div", {
|
|
198
|
+
className: "textToolOperationMenu"
|
|
199
|
+
}, configList.map((i, index) => /* @__PURE__ */ React.createElement(SingleTextInput, {
|
|
200
|
+
config: i,
|
|
201
|
+
key: i.key,
|
|
202
|
+
index,
|
|
203
|
+
result,
|
|
204
|
+
updateText,
|
|
205
|
+
switchToNextTextarea,
|
|
206
|
+
hasMultiple: configList.length > 1,
|
|
207
|
+
focus: focusIndex === index,
|
|
208
|
+
onNext,
|
|
209
|
+
disabled
|
|
210
|
+
})));
|
|
211
|
+
};
|
|
212
|
+
function mapStateToProps(state) {
|
|
213
|
+
return {
|
|
214
|
+
toolInstance: state.annotation.toolInstance,
|
|
215
|
+
imgIndex: state.annotation.imgIndex,
|
|
216
|
+
step: state.annotation.step,
|
|
217
|
+
basicResultList: state.annotation.basicResultList,
|
|
218
|
+
stepList: state.annotation.stepList,
|
|
219
|
+
triggerEventAfterIndexChanged: state.annotation.triggerEventAfterIndexChanged
|
|
220
|
+
};
|
|
221
|
+
}
|
|
222
|
+
var TextToolSidebar$1 = connect(mapStateToProps, null, null, {context: LabelBeeContext})(TextToolSidebar);
|
|
223
|
+
|
|
224
|
+
export { SingleTextInput, TextareaWithFooter, TextToolSidebar$1 as default };
|
|
225
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../../src/views/MainView/sidebar/TextToolSidebar/index.tsx"],"sourcesContent":["import React, { useEffect, useState, useRef, FocusEvent } from 'react';\nimport { connect } from 'react-redux';\nimport { AppState } from '@/store';\nimport { cloneDeep } from 'lodash';\nimport { classnames } from '@/utils';\nimport { Input } from 'antd/es';\nimport { cKeyCode } from '@labelbee/lb-annotation';\nimport { PageForward } from '@/store/annotation/actionCreators';\nimport { ConfigUtils } from '@/utils/ConfigUtils';\nimport { IStepInfo } from '@/types/step';\nimport TextToolOperation from '@labelbee/lb-annotation/dist/types/core/toolOperation/TextToolOperation';\nimport { useTranslation } from 'react-i18next';\nimport { LabelBeeContext } from '@/store/ctx';\n\nconst EKeyCode = cKeyCode.default;\n\nconst syntheticEventStopPagination = (e: React.KeyboardEvent<HTMLTextAreaElement>) => {\n e.stopPropagation();\n e.nativeEvent.stopPropagation();\n e.nativeEvent.stopImmediatePropagation();\n};\n\ninterface ITextareaWithFooterProps {\n textareaProps?: any;\n footer?: any;\n}\n\nexport const TextareaWithFooter = (props: ITextareaWithFooterProps) => {\n const { textareaProps, footer } = props;\n\n return (\n <>\n <Input.TextArea\n bordered={false}\n rows={6}\n onKeyDown={syntheticEventStopPagination}\n onKeyUp={syntheticEventStopPagination}\n {...textareaProps}\n />\n <div\n className={classnames({\n textAreaLength: true,\n })}\n >\n {footer}\n </div>\n </>\n );\n};\n\ninterface IProps {\n dispatch: Function;\n toolInstance: TextToolOperation;\n imgIndex: number;\n triggerEventAfterIndexChanged: boolean;\n step: number;\n stepList: IStepInfo[];\n basicResultList: any[];\n}\n\ninterface IConfigListItem {\n label: string;\n key: string;\n required: boolean;\n default: string;\n maxLength: number;\n}\n\nexport const SingleTextInput = (props: any) => {\n const ref = useRef(null);\n const [textAreaFocus, setTextAreaFocus] = useState(false);\n const [invalid, setInvalid] = useState(false);\n const { t } = useTranslation();\n\n const { disabled, config, result, updateText, index, switchToNextTextarea, hasMultiple, onNext } =\n props;\n const { maxLength } = config;\n\n const value = result ? result[config.key] : '';\n const textLength = value?.length ?? 0;\n\n const updateTextWithKey = (newVal: string) => {\n if (updateText) {\n updateText(newVal, config.key);\n if (config.required) {\n setInvalid(!newVal);\n }\n }\n };\n\n const tabToSwitchEnabled = hasMultiple && switchToNextTextarea;\n\n const textareaProps = {\n id: `textInput-${index}`,\n ref,\n disabled,\n value,\n maxLength,\n autoSize: { minRows: 2, maxRows: 6 },\n onChange: (e: FocusEvent<HTMLTextAreaElement>) => {\n const value = e.target.value;\n updateTextWithKey(value);\n },\n onFocus: () => {\n setTextAreaFocus(true);\n },\n onBlur: (e: FocusEvent<HTMLTextAreaElement>) => {\n setTextAreaFocus(false);\n if (config.required) {\n setInvalid(!e.target.value);\n }\n },\n style: {\n resize: 'none',\n wordBreak: 'break-all',\n },\n onKeyDownCapture: (e: React.KeyboardEvent) => {\n if (e.ctrlKey && e.keyCode === EKeyCode.Enter) {\n if (onNext) {\n onNext();\n }\n e.preventDefault();\n }\n\n if (e.keyCode === EKeyCode.Tab && tabToSwitchEnabled) {\n e.preventDefault();\n e.nativeEvent.stopImmediatePropagation();\n switchToNextTextarea(index);\n }\n\n e.nativeEvent.stopPropagation();\n },\n };\n\n const TextareaFooter = (\n <div className='textAreaFooter'>\n <div className='hotkeyTip'>\n {tabToSwitchEnabled && <span>{`[${t('Switch')}]Tab`}</span>}\n <span>{`[${t('TurnPage')}]Ctrl+Enter`}</span>\n </div>\n <div className='wordCount'>\n <span className={textLength >= maxLength ? 'warning' : ''}>{textLength}</span>/\n <span>{maxLength}</span>\n </div>\n </div>\n );\n\n useEffect(() => {\n if (disabled) {\n setTextAreaFocus(false);\n }\n }, [disabled]);\n\n return (\n <div className='textField'>\n <div className='label'>\n <span className={classnames({ required: config.required })}>{config.label}</span>\n <i\n className={classnames({ clearText: true, disabled: disabled })}\n onClick={() => {\n if (disabled) {\n return;\n }\n updateTextWithKey('');\n }}\n />\n </div>\n <div\n className={classnames({\n disabled,\n 'textarea-outline': true,\n 'ant-input-focused': textAreaFocus,\n textareaContainer: true,\n focus: textAreaFocus,\n invalid: invalid,\n })}\n >\n <TextareaWithFooter footer={TextareaFooter} textareaProps={textareaProps} />\n </div>\n </div>\n );\n};\n\nconst TextToolSidebar: React.FC<IProps> = ({\n toolInstance,\n imgIndex,\n dispatch,\n triggerEventAfterIndexChanged,\n step,\n stepList,\n basicResultList,\n}) => {\n const [configList, setConfigList] = useState<IConfigListItem[]>([]);\n const [focusIndex, setFocusIndex] = useState(0);\n const [, forceRender] = useState(0);\n\n const switchToNextTextarea = (currentIndex: number) => {\n const nextIndex = (currentIndex + 1) % configList.length;\n textareaFocus(nextIndex);\n };\n\n const textareaFocus = (index: number) => {\n setTimeout(() => {\n const textarea = document.getElementById(`textInput-${index}`) as HTMLTextAreaElement;\n if (textarea) {\n setFocusIndex(index);\n textarea.focus();\n textarea.select();\n textarea.scrollIntoView({ behavior: 'smooth', block: 'center' });\n }\n });\n };\n\n useEffect(() => {\n if (toolInstance) {\n setConfigList(cloneDeep(toolInstance.config.configList));\n toolInstance.singleOn('valueUpdated', () => {\n forceRender((s) => s + 1);\n });\n }\n }, [toolInstance]);\n\n const updateText = (v: string, k: string) => {\n toolInstance.updateTextValue(k, v);\n };\n\n useEffect(() => {\n if (imgIndex > -1 && triggerEventAfterIndexChanged) {\n textareaFocus(0);\n }\n }, [imgIndex]);\n\n const result = toolInstance.textList[0]?.value ?? {};\n\n const onNext = () => {\n dispatch(PageForward(true));\n };\n\n const stepConfig = ConfigUtils.getStepConfig(stepList, step);\n const disabled = stepConfig.dataSourceStep > 0 && basicResultList.length === 0;\n\n return (\n <div className='textToolOperationMenu'>\n {configList.map((i, index) => (\n <SingleTextInput\n config={i}\n key={i.key}\n index={index}\n result={result}\n updateText={updateText}\n switchToNextTextarea={switchToNextTextarea}\n hasMultiple={configList.length > 1}\n focus={focusIndex === index}\n onNext={onNext}\n disabled={disabled}\n />\n ))}\n </div>\n );\n};\n\nfunction mapStateToProps(state: AppState) {\n return {\n toolInstance: state.annotation.toolInstance,\n imgIndex: state.annotation.imgIndex,\n step: state.annotation.step,\n basicResultList: state.annotation.basicResultList,\n stepList: state.annotation.stepList,\n triggerEventAfterIndexChanged: state.annotation.triggerEventAfterIndexChanged,\n };\n}\n\nexport default connect(mapStateToProps, null, null, { context: LabelBeeContext })(TextToolSidebar);\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAcA,MAAM,WAAW,QAAS,CAAA,OAAA,CAAA;AAE1B,MAAM,4BAAA,GAA+B,CAAC,CAAgD,KAAA;AACpF,EAAE,CAAA,CAAA,eAAA,EAAA,CAAA;AACF,EAAA,CAAA,CAAE,WAAY,CAAA,eAAA,EAAA,CAAA;AACd,EAAA,C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