@glodon-aiot/dataset-annotation 3.2.2-beta.3 → 3.2.2-beta.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/es/Common/Page/index.mjs +29 -0
- package/dist/es/Common/Page/style.less.mjs +4 -0
- package/dist/es/Common/PageContent/index.mjs +18 -0
- package/dist/es/Common/PageHeader/index.mjs +39 -0
- package/dist/es/Common/PageHeader/style.less.mjs +4 -0
- package/dist/es/DatasetContext/index.mjs +11 -0
- package/dist/es/_virtual/_commonjsHelpers.mjs +4 -0
- package/dist/es/_virtual/minio.mjs +4 -0
- package/dist/es/access/images/data_empty.svg.mjs +4 -0
- package/dist/es/components/CompositionInput/index.mjs +53 -0
- package/dist/es/components/DataEmpty/index.mjs +51 -0
- package/dist/es/components/DataEmpty/style.less.mjs +4 -0
- package/dist/es/components/DetectionAnnotation/PreSamplesPage/index.mjs +292 -0
- package/dist/es/components/DetectionAnnotation/PreSamplesPage/style.less.mjs +4 -0
- package/dist/es/components/DetectionAnnotation/components/DisabledTooltip/index.mjs +23 -0
- package/dist/es/components/DetectionAnnotation/components/ImageDetail/index.mjs +166 -0
- package/dist/es/components/DetectionAnnotation/components/ImageDetail/style.less.mjs +4 -0
- package/dist/es/components/DetectionAnnotation/components/LabelMaker/Drawable.mjs +51 -0
- package/dist/es/components/DetectionAnnotation/components/LabelMaker/FabricCustomize.mjs +42 -0
- package/dist/es/components/DetectionAnnotation/components/LabelMaker/RectLabel.mjs +283 -0
- package/dist/es/components/DetectionAnnotation/components/LabelMaker/icons/delete-icon.svg.mjs +4 -0
- package/dist/es/components/DetectionAnnotation/components/LabelMaker/index.mjs +315 -0
- package/dist/es/components/DetectionAnnotation/components/LabelMaker/style.less.mjs +4 -0
- package/dist/es/components/DetectionAnnotation/components/Labels/index.mjs +201 -0
- package/dist/es/components/DetectionAnnotation/components/Labels/style.less.mjs +4 -0
- package/dist/es/components/DetectionAnnotation/components/TagItem/index.mjs +144 -0
- package/dist/es/components/DetectionAnnotation/components/TagItem/style.less.mjs +4 -0
- package/dist/es/components/DetectionAnnotation/icon_item_empty.svg.mjs +4 -0
- package/dist/es/components/DetectionAnnotation/index.mjs +713 -0
- package/dist/es/components/DetectionAnnotation/style.less.mjs +4 -0
- package/dist/es/components/DetectionImageAnnotation/index.mjs +62 -0
- package/dist/es/components/DetectionImageAnnotation/style.less.mjs +4 -0
- package/dist/es/components/Iconfont/index.mjs +16 -0
- package/dist/es/components/MarkDescriptions/index.mjs +66 -0
- package/dist/es/components/MarkDescriptions/style.less.mjs +4 -0
- package/dist/es/components/OCRImageViewer/index.mjs +213 -0
- package/dist/es/components/OCRImageViewer/style.less.mjs +4 -0
- package/dist/es/components/OcrAnnotation/MarkKVOCRModal/CategoryDrawer.mjs +136 -0
- package/dist/es/components/OcrAnnotation/MarkKVOCRModal/KVOCRLabelMaker/LabelEditorInput.mjs +57 -0
- package/dist/es/components/OcrAnnotation/MarkKVOCRModal/KVOCRLabelMaker/LabelEditorItem.mjs +73 -0
- package/dist/es/components/OcrAnnotation/MarkKVOCRModal/KVOCRLabelMaker/LableEditor.mjs +55 -0
- package/dist/es/components/OcrAnnotation/MarkKVOCRModal/KVOCRLabelMaker/index.mjs +366 -0
- package/dist/es/components/OcrAnnotation/MarkKVOCRModal/KVOCRLabelMaker/style.less.mjs +4 -0
- package/dist/es/components/OcrAnnotation/MarkKVOCRModal/index.mjs +255 -0
- package/dist/es/components/OcrAnnotation/MarkKVOCRModal/style.less.mjs +4 -0
- package/dist/es/components/OcrAnnotation/MarkOCRBoxModal/ImageDetail/index.mjs +101 -0
- package/dist/es/components/OcrAnnotation/MarkOCRBoxModal/ImageDetail/style.less.mjs +4 -0
- package/dist/es/components/OcrAnnotation/MarkOCRBoxModal/OCRBoxMaker/images/delete.png.mjs +4 -0
- package/dist/es/components/OcrAnnotation/MarkOCRBoxModal/OCRBoxMaker/index.mjs +756 -0
- package/dist/es/components/OcrAnnotation/MarkOCRBoxModal/OCRBoxMaker/style.less.mjs +4 -0
- package/dist/es/components/OcrAnnotation/MarkOCRBoxModal/index.mjs +231 -0
- package/dist/es/components/OcrAnnotation/MarkOCRBoxModal/style.less.mjs +4 -0
- package/dist/es/components/OcrAnnotation/OcrModal/index.mjs +180 -0
- package/dist/es/components/OcrAnnotation/OcrModal/style.less.mjs +4 -0
- package/dist/es/components/OcrAnnotation/PreLabelOCR/PreLabelModal.mjs +281 -0
- package/dist/es/components/OcrAnnotation/PreLabelOCR/index.mjs +44 -0
- package/dist/es/components/OcrAnnotation/PreLabelOCR/style.less.mjs +4 -0
- package/dist/es/components/OcrAnnotation/constant.mjs +5 -0
- package/dist/es/components/OcrAnnotation/index.mjs +382 -0
- package/dist/es/components/OcrAnnotation/style.less.mjs +4 -0
- package/dist/es/components/OcrImageAnnotation/index.mjs +40 -0
- package/dist/es/components/OcrImageAnnotation/style.less.mjs +4 -0
- package/dist/es/components/PageNav/index.mjs +30 -0
- package/dist/es/components/PageNav/style.less.mjs +4 -0
- package/dist/es/components/PicZipImportModal/index.mjs +584 -0
- package/dist/es/components/PicZipImportModal/pic_zip.svg.mjs +4 -0
- package/dist/es/components/PicZipImportModal/pic_zip_json.svg.mjs +4 -0
- package/dist/es/components/PicZipImportModal/style.less.mjs +4 -0
- package/dist/es/components/PreLabelOCR/PreLabelModal.mjs +276 -0
- package/dist/es/components/PreLabelOCR/index.mjs +44 -0
- package/dist/es/components/PreLabelOCR/style.less.mjs +4 -0
- package/dist/es/components/ScanTable/index.mjs +97 -0
- package/dist/es/components/ScanTable/style.less.mjs +4 -0
- package/dist/es/components/Thumbnail/default.png.mjs +4 -0
- package/dist/es/components/Thumbnail/index.mjs +31 -0
- package/dist/es/components/Thumbnail/style.less.mjs +4 -0
- package/dist/es/components/hooks/Prompt.mjs +33 -0
- package/dist/es/constant.mjs +13 -0
- package/dist/es/createDatasetAnnotation/index.mjs +133 -0
- package/dist/es/createDetectionDatasetAnnotation/index.mjs +129 -0
- package/dist/es/createDetectionImageAnnotation/index.mjs +31 -0
- package/dist/es/createOcrDatasetAnnotation/index.mjs +129 -0
- package/dist/es/createOcrImageAnnotation/index.mjs +33 -0
- package/dist/es/featuresConfig.mjs +79 -0
- package/dist/es/index.mjs +13 -0
- package/dist/es/node_modules/@glodon-aiot/minio/dist/minio.mjs +28463 -0
- package/dist/es/utils/color.mjs +30 -0
- package/dist/es/utils/index.mjs +22 -0
- package/dist/es/utils/sign.mjs +33 -0
- package/dist/lib/index.js +130 -0
- package/dist/src/Common/Page/index.d.ts +1 -2
- package/dist/src/Common/PageHeader/index.d.ts +0 -1
- package/dist/src/DatasetContext/index.d.ts +3 -4
- package/dist/src/components/CompositionInput/index.d.ts +2 -2
- package/dist/src/components/DataEmpty/index.d.ts +1 -2
- package/dist/src/components/DetectionAnnotation/PreSamplesPage/index.d.ts +1 -2
- package/dist/src/components/DetectionAnnotation/components/DisabledTooltip/index.d.ts +2 -2
- package/dist/src/components/DetectionAnnotation/components/ImageDetail/index.d.ts +1 -2
- package/dist/src/components/DetectionAnnotation/components/LabelMaker/Drawable.d.ts +2 -2
- package/dist/src/components/DetectionAnnotation/components/LabelMaker/RectLabel.d.ts +6 -5
- package/dist/src/components/DetectionAnnotation/components/LabelMaker/index.d.ts +0 -1
- package/dist/src/components/DetectionAnnotation/components/Labels/index.d.ts +0 -1
- package/dist/src/components/DetectionAnnotation/components/TagItem/index.d.ts +1 -2
- package/dist/src/components/DetectionAnnotation/index.d.ts +1 -2
- package/dist/src/components/DetectionImageAnnotation/index.d.ts +0 -2
- package/dist/src/components/Iconfont/font_3140028_iptomfpgyu.d.ts +0 -0
- package/dist/src/components/Iconfont/font_3454453_gu5ijeufyng.d.ts +0 -0
- package/dist/src/components/Iconfont/font_4108228_3slzqhoow93.d.ts +0 -0
- package/dist/src/components/Iconfont/font_4439177_k3mjwv7kzfd.d.ts +0 -0
- package/dist/src/components/Iconfont/index.d.ts +1 -2
- package/dist/src/components/MarkDescriptions/index.d.ts +0 -1
- package/dist/src/components/OCRImageViewer/index.d.ts +1 -2
- package/dist/src/components/OcrAnnotation/MarkKVOCRModal/KVOCRLabelMaker/LabelEditorInput.d.ts +2 -2
- package/dist/src/components/OcrAnnotation/MarkKVOCRModal/KVOCRLabelMaker/LabelEditorItem.d.ts +1 -2
- package/dist/src/components/OcrAnnotation/MarkKVOCRModal/KVOCRLabelMaker/LableEditor.d.ts +0 -1
- package/dist/src/components/OcrAnnotation/MarkKVOCRModal/index.d.ts +0 -1
- package/dist/src/components/OcrAnnotation/MarkOCRBoxModal/ImageDetail/index.d.ts +1 -2
- package/dist/src/components/OcrAnnotation/MarkOCRBoxModal/OCRBoxMaker/LabelEditorInput.d.ts +2 -2
- package/dist/src/components/OcrAnnotation/MarkOCRBoxModal/OCRBoxMaker/LabelEditorItem.d.ts +0 -1
- package/dist/src/components/OcrAnnotation/MarkOCRBoxModal/OCRBoxMaker/LableEditor.d.ts +0 -1
- package/dist/src/components/OcrAnnotation/MarkOCRBoxModal/OCRBoxMaker/index.d.ts +0 -1
- package/dist/src/components/OcrAnnotation/MarkOCRBoxModal/index.d.ts +0 -1
- package/dist/src/components/OcrAnnotation/OcrModal/index.d.ts +1 -2
- package/dist/src/components/OcrAnnotation/PreLabelOCR/PreLabelModal.d.ts +1 -2
- package/dist/src/components/OcrAnnotation/PreLabelOCR/index.d.ts +1 -2
- package/dist/src/components/OcrAnnotation/index.d.ts +1 -2
- package/dist/src/components/OcrImageAnnotation/index.d.ts +0 -2
- package/dist/src/components/PageNav/index.d.ts +1 -2
- package/dist/src/components/PicZipImportModal/index.d.ts +1 -2
- package/dist/src/components/PreLabelOCR/PreLabelModal.d.ts +1 -2
- package/dist/src/components/PreLabelOCR/index.d.ts +1 -2
- package/dist/src/components/ScanTable/index.d.ts +1 -2
- package/dist/src/components/Thumbnail/index.d.ts +1 -2
- package/dist/src/components/hooks/Prompt.d.ts +0 -1
- package/dist/src/components/hooks/useBlocker.d.ts +1 -1
- package/dist/src/featuresConfig.d.ts +1 -1
- package/dist/src/utils/sign.d.ts +1 -1
- package/package.json +15 -6
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { jsxs as a, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { Layout as m } from "antd";
|
|
3
|
+
import n from "../PageContent/index.mjs";
|
|
4
|
+
import l from "../PageHeader/index.mjs";
|
|
5
|
+
import "./style.less.mjs";
|
|
6
|
+
const g = (e) => {
|
|
7
|
+
const {
|
|
8
|
+
title: t,
|
|
9
|
+
header: r,
|
|
10
|
+
className: i
|
|
11
|
+
} = e;
|
|
12
|
+
return /* @__PURE__ */ a(m, {
|
|
13
|
+
style: {
|
|
14
|
+
height: "100%",
|
|
15
|
+
width: "100%",
|
|
16
|
+
overflow: "hidden"
|
|
17
|
+
},
|
|
18
|
+
className: i,
|
|
19
|
+
children: [r, !r && t && /* @__PURE__ */ o(l, {
|
|
20
|
+
className: "content-title",
|
|
21
|
+
title: t
|
|
22
|
+
}), /* @__PURE__ */ o(n, {
|
|
23
|
+
children: e.children
|
|
24
|
+
})]
|
|
25
|
+
});
|
|
26
|
+
};
|
|
27
|
+
export {
|
|
28
|
+
g as default
|
|
29
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { jsx as n } from "react/jsx-runtime";
|
|
2
|
+
function r(o) {
|
|
3
|
+
const {
|
|
4
|
+
children: e
|
|
5
|
+
} = o;
|
|
6
|
+
return /* @__PURE__ */ n("div", {
|
|
7
|
+
style: {
|
|
8
|
+
padding: 16,
|
|
9
|
+
backgroundColor: "#F7F7F9",
|
|
10
|
+
overflow: "hidden",
|
|
11
|
+
height: "100%"
|
|
12
|
+
},
|
|
13
|
+
children: e
|
|
14
|
+
});
|
|
15
|
+
}
|
|
16
|
+
export {
|
|
17
|
+
r as default
|
|
18
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { jsxs as c, jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import d from "classnames";
|
|
3
|
+
import "./style.less.mjs";
|
|
4
|
+
function u(l) {
|
|
5
|
+
const {
|
|
6
|
+
breadcrumb: e,
|
|
7
|
+
title: i,
|
|
8
|
+
icon: o,
|
|
9
|
+
actions: s,
|
|
10
|
+
className: m,
|
|
11
|
+
children: n
|
|
12
|
+
} = l, t = !!n, r = d({
|
|
13
|
+
"page-header bg-white h-auto leading-none content-title": !0
|
|
14
|
+
});
|
|
15
|
+
return /* @__PURE__ */ c("div", {
|
|
16
|
+
className: r,
|
|
17
|
+
style: {
|
|
18
|
+
padding: `${t ? "16" : "24"}px 22px ${t ? "0" : "24"}px 22px`
|
|
19
|
+
},
|
|
20
|
+
children: [e && /* @__PURE__ */ a("div", {
|
|
21
|
+
children: e
|
|
22
|
+
}), /* @__PURE__ */ c("div", {
|
|
23
|
+
className: "title-bar flex justify-between items-center",
|
|
24
|
+
style: {
|
|
25
|
+
marginTop: `${t && e ? "16" : "0"}px`
|
|
26
|
+
},
|
|
27
|
+
children: [i && /* @__PURE__ */ a("div", {
|
|
28
|
+
className: "title",
|
|
29
|
+
children: i
|
|
30
|
+
}), s && /* @__PURE__ */ a("div", {
|
|
31
|
+
className: "actions",
|
|
32
|
+
children: s
|
|
33
|
+
})]
|
|
34
|
+
}), n]
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
export {
|
|
38
|
+
u as default
|
|
39
|
+
};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
const N = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iODIiIGhlaWdodD0iOTAiIHZpZXdCb3g9IjAgMCA4MiA5MCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0yOS4xMiA2MC4zMTAxQzI5LjA0IDYwLjg2MDEgMjkgNjEuNDMgMjkgNjJDMjkgNjguNjMgMzQuMzcgNzQgNDEgNzR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Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+CjxwYXRoIGQ9Ik00MC4xIDE4Ljc2VjJNMjUuMSAxOC43NkwxNCA2LjMwMDA1TTY2LjEgNi4zMDAwNUw1NSAxOC43NiIgc3Ryb2tlPSIjOUMyNEYyIiBzdHJva2Utd2lkdGg9IjIuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+CjxkZWZzPgo8bGluZWFyR3JhZGllbnQgaWQ9InBhaW50MF9saW5lYXJfNDc4M18xNTE4NSIgeDE9IjU4LjM1NzMiIHkxPSI3NSIgeDI9IjcwLjYyNTIiIHkyPSI3NSIgZ3JhZGllbnRVbml0cz0idXNlclNwYWNlT25Vc2UiPgo8c3RvcCBzdG9wLWNvbG9yPSIjMjA1RUY5Ii8+CjxzdG9wIG9mZnNldD0iMC42IiBzdG9wLWNvbG9yPSIjODM1QUZFIi8+CjxzdG9wIG9mZnNldD0iMSIgc3RvcC1jb2xvcj0iI0ZENjJEOSIvPgo8L2xpbmVhckdyYWRpZW50Pgo8L2RlZnM+Cjwvc3ZnPgo=";
|
|
2
|
+
export {
|
|
3
|
+
N as default
|
|
4
|
+
};
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
var V = Object.defineProperty, b = Object.defineProperties;
|
|
2
|
+
var j = Object.getOwnPropertyDescriptors;
|
|
3
|
+
var n = Object.getOwnPropertySymbols;
|
|
4
|
+
var c = Object.prototype.hasOwnProperty, l = Object.prototype.propertyIsEnumerable;
|
|
5
|
+
var p = (o, e, t) => e in o ? V(o, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : o[e] = t, f = (o, e) => {
|
|
6
|
+
for (var t in e || (e = {}))
|
|
7
|
+
c.call(e, t) && p(o, t, e[t]);
|
|
8
|
+
if (n)
|
|
9
|
+
for (var t of n(e))
|
|
10
|
+
l.call(e, t) && p(o, t, e[t]);
|
|
11
|
+
return o;
|
|
12
|
+
}, C = (o, e) => b(o, j(e));
|
|
13
|
+
var d = (o, e) => {
|
|
14
|
+
var t = {};
|
|
15
|
+
for (var s in o)
|
|
16
|
+
c.call(o, s) && e.indexOf(s) < 0 && (t[s] = o[s]);
|
|
17
|
+
if (o != null && n)
|
|
18
|
+
for (var s of n(o))
|
|
19
|
+
e.indexOf(s) < 0 && l.call(o, s) && (t[s] = o[s]);
|
|
20
|
+
return t;
|
|
21
|
+
};
|
|
22
|
+
import { jsx as w } from "react/jsx-runtime";
|
|
23
|
+
import { Input as A } from "antd";
|
|
24
|
+
import K, { useState as g, useEffect as O } from "react";
|
|
25
|
+
const P = (o) => {
|
|
26
|
+
const u = o, {
|
|
27
|
+
value: e,
|
|
28
|
+
onChange: t
|
|
29
|
+
} = u, s = d(u, [
|
|
30
|
+
"value",
|
|
31
|
+
"onChange"
|
|
32
|
+
]), [v, r] = g(e), [h, a] = g(!1), x = navigator.userAgent.indexOf("WebKit") > -1;
|
|
33
|
+
O(() => {
|
|
34
|
+
r(e);
|
|
35
|
+
}, [e]);
|
|
36
|
+
const E = () => {
|
|
37
|
+
a(!0);
|
|
38
|
+
}, I = (i) => {
|
|
39
|
+
a(!1), x && (t == null || t(i.currentTarget.value));
|
|
40
|
+
}, S = (i) => {
|
|
41
|
+
const m = i.target.value;
|
|
42
|
+
r(m), h || t == null || t(m);
|
|
43
|
+
};
|
|
44
|
+
return /* @__PURE__ */ w(A, C(f({}, s), {
|
|
45
|
+
value: v,
|
|
46
|
+
onChange: S,
|
|
47
|
+
onCompositionStart: E,
|
|
48
|
+
onCompositionEnd: I
|
|
49
|
+
}));
|
|
50
|
+
}, k = K.memo(P);
|
|
51
|
+
export {
|
|
52
|
+
k as default
|
|
53
|
+
};
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
var y = Object.defineProperty;
|
|
2
|
+
var a = Object.getOwnPropertySymbols;
|
|
3
|
+
var h = Object.prototype.hasOwnProperty, N = Object.prototype.propertyIsEnumerable;
|
|
4
|
+
var c = (s, t, e) => t in s ? y(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e, m = (s, t) => {
|
|
5
|
+
for (var e in t || (t = {}))
|
|
6
|
+
h.call(t, e) && c(s, e, t[e]);
|
|
7
|
+
if (a)
|
|
8
|
+
for (var e of a(t))
|
|
9
|
+
N.call(t, e) && c(s, e, t[e]);
|
|
10
|
+
return s;
|
|
11
|
+
};
|
|
12
|
+
import { jsx as i, jsxs as x } from "react/jsx-runtime";
|
|
13
|
+
import { Empty as f, Button as u } from "antd";
|
|
14
|
+
import k from "../../access/images/data_empty.svg.mjs";
|
|
15
|
+
import "./style.less.mjs";
|
|
16
|
+
const b = (s) => {
|
|
17
|
+
const {
|
|
18
|
+
emptyClassName: t,
|
|
19
|
+
emptyStyle: e,
|
|
20
|
+
image: n,
|
|
21
|
+
description: l,
|
|
22
|
+
showBtn: o,
|
|
23
|
+
btnText: r,
|
|
24
|
+
children: p,
|
|
25
|
+
handleClick: d
|
|
26
|
+
} = s;
|
|
27
|
+
return /* @__PURE__ */ i(f, {
|
|
28
|
+
className: `unit-empty ${t || ""}`,
|
|
29
|
+
style: m({}, e),
|
|
30
|
+
image: n || k,
|
|
31
|
+
description: /* @__PURE__ */ x("div", {
|
|
32
|
+
className: "descriptions",
|
|
33
|
+
children: [/* @__PURE__ */ i("span", {
|
|
34
|
+
className: "desc",
|
|
35
|
+
children: l || "暂无数据"
|
|
36
|
+
}), o && /* @__PURE__ */ i(u, {
|
|
37
|
+
className: "action",
|
|
38
|
+
type: "link",
|
|
39
|
+
onClick: d,
|
|
40
|
+
children: /* @__PURE__ */ i("span", {
|
|
41
|
+
className: "action-text",
|
|
42
|
+
children: r
|
|
43
|
+
})
|
|
44
|
+
})]
|
|
45
|
+
}),
|
|
46
|
+
children: p || ""
|
|
47
|
+
});
|
|
48
|
+
};
|
|
49
|
+
export {
|
|
50
|
+
b as default
|
|
51
|
+
};
|
|
@@ -0,0 +1,292 @@
|
|
|
1
|
+
var Y = Object.defineProperty, Z = Object.defineProperties;
|
|
2
|
+
var _ = Object.getOwnPropertyDescriptors;
|
|
3
|
+
var B = Object.getOwnPropertySymbols;
|
|
4
|
+
var $ = Object.prototype.hasOwnProperty, ee = Object.prototype.propertyIsEnumerable;
|
|
5
|
+
var H = (h, s, a) => s in h ? Y(h, s, { enumerable: !0, configurable: !0, writable: !0, value: a }) : h[s] = a, y = (h, s) => {
|
|
6
|
+
for (var a in s || (s = {}))
|
|
7
|
+
$.call(s, a) && H(h, a, s[a]);
|
|
8
|
+
if (B)
|
|
9
|
+
for (var a of B(s))
|
|
10
|
+
ee.call(s, a) && H(h, a, s[a]);
|
|
11
|
+
return h;
|
|
12
|
+
}, D = (h, s) => Z(h, _(s));
|
|
13
|
+
import { jsxs as E, jsx as m } from "react/jsx-runtime";
|
|
14
|
+
import { useContext as te, useRef as re, useState as b, useEffect as k } from "react";
|
|
15
|
+
import { Button as V, Space as ne, message as L, Modal as K } from "antd";
|
|
16
|
+
import "./style.less.mjs";
|
|
17
|
+
import { useKeyPress as ie } from "ahooks";
|
|
18
|
+
import le from "../components/ImageDetail/index.mjs";
|
|
19
|
+
import se from "../../../DatasetContext/index.mjs";
|
|
20
|
+
import { tagColors as oe } from "../../../utils/index.mjs";
|
|
21
|
+
import ce from "../../../Common/Page/index.mjs";
|
|
22
|
+
const be = (h) => {
|
|
23
|
+
const {
|
|
24
|
+
datasetId: s,
|
|
25
|
+
versionId: a,
|
|
26
|
+
onClose: S,
|
|
27
|
+
samples: M,
|
|
28
|
+
labels: q,
|
|
29
|
+
fetchLength: F
|
|
30
|
+
} = h, {
|
|
31
|
+
services: {
|
|
32
|
+
cvforceDatahub: p
|
|
33
|
+
},
|
|
34
|
+
featuresConfig: {
|
|
35
|
+
datasetManager: R
|
|
36
|
+
} = {
|
|
37
|
+
datasetManager: !1
|
|
38
|
+
}
|
|
39
|
+
} = te(se), G = re(null), [N, J] = b(!1), [Q, j] = b(!1), [C, v] = b(0), [d, g] = b(), [f, x] = b(), [c, P] = b({
|
|
40
|
+
current: 1,
|
|
41
|
+
pageSize: 1e4
|
|
42
|
+
}), [u, z] = b([]), A = (t) => {
|
|
43
|
+
if (!p)
|
|
44
|
+
return Promise.resolve(!1);
|
|
45
|
+
const e = (t == null ? void 0 : t.current) || c.current, r = (t == null ? void 0 : t.pageSize) || c.pageSize;
|
|
46
|
+
return !s || !a || !e ? Promise.resolve(!1) : (P(D(y({}, c), {
|
|
47
|
+
current: e,
|
|
48
|
+
pageSize: r
|
|
49
|
+
})), p.getDatasetsIdVersionsVidSamples(s, a, {
|
|
50
|
+
pageNo: e,
|
|
51
|
+
pageSize: r,
|
|
52
|
+
confirmStatus: 1
|
|
53
|
+
}).then((l) => {
|
|
54
|
+
const o = l.recordList || [];
|
|
55
|
+
if (o.length === 0)
|
|
56
|
+
return S(), !1;
|
|
57
|
+
const n = e === 1 ? o : [...M, ...o];
|
|
58
|
+
if (z(n), P(D(y({}, c), {
|
|
59
|
+
current: e,
|
|
60
|
+
pageSize: r,
|
|
61
|
+
total: l.totalResults
|
|
62
|
+
})), c.type === "next" && o.length) {
|
|
63
|
+
v(0);
|
|
64
|
+
const i = l.recordList[0];
|
|
65
|
+
g(i);
|
|
66
|
+
}
|
|
67
|
+
if (c.type === "prev" && o.length) {
|
|
68
|
+
v(c.pageSize - 1);
|
|
69
|
+
const i = l.recordList[c.pageSize - 1];
|
|
70
|
+
g(i);
|
|
71
|
+
}
|
|
72
|
+
return N && C < 0 && (v(0), g(o[0]), j(!0)), n;
|
|
73
|
+
}).catch(() => !1));
|
|
74
|
+
};
|
|
75
|
+
k(() => {
|
|
76
|
+
!d && !C && g(u[0]);
|
|
77
|
+
}, [u]), ie("Esc", S), k(() => {
|
|
78
|
+
A(c).then((t) => {
|
|
79
|
+
});
|
|
80
|
+
}, [c.current]), k(() => {
|
|
81
|
+
!N && d && J(!0);
|
|
82
|
+
}, [d]);
|
|
83
|
+
const U = () => {
|
|
84
|
+
if (!(!s || !a) && p)
|
|
85
|
+
return p.getDatasetsIdVersionsVidLabelcount(s, a).then((t) => ((t || []).filter((r) => r.label !== "nocode").map((r, l) => ({
|
|
86
|
+
label: r.label,
|
|
87
|
+
count: r.count,
|
|
88
|
+
id: r.id,
|
|
89
|
+
color: oe[l % 40]
|
|
90
|
+
})), t));
|
|
91
|
+
};
|
|
92
|
+
k(() => {
|
|
93
|
+
c.type || A();
|
|
94
|
+
}, [c.type]);
|
|
95
|
+
const O = (t) => {
|
|
96
|
+
if (u)
|
|
97
|
+
return T(t).then((e) => (e && z((r) => {
|
|
98
|
+
var o;
|
|
99
|
+
let l;
|
|
100
|
+
if (Array.isArray(r)) {
|
|
101
|
+
if (!r.length)
|
|
102
|
+
return S(), r;
|
|
103
|
+
const n = t ? C + 1 : C;
|
|
104
|
+
if (f || d) {
|
|
105
|
+
const i = f || d;
|
|
106
|
+
if (i && ((o = i.labels) != null && o.length) && t === 0) {
|
|
107
|
+
const I = r.findIndex((w) => w.id === i.id);
|
|
108
|
+
I > -1 && (r.splice(I, 1), l = [...r]);
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
n >= r.length ? n === u.length ? L.error("已经是最后一个了") : A({
|
|
112
|
+
current: c.current,
|
|
113
|
+
pageSize: c.pageSize,
|
|
114
|
+
type: "next"
|
|
115
|
+
}).then((i) => {
|
|
116
|
+
if (Array.isArray(i)) {
|
|
117
|
+
v(n >= i.length ? n - 1 : n);
|
|
118
|
+
const I = i[n >= i.length ? n - 1 : n];
|
|
119
|
+
g(I), x(void 0);
|
|
120
|
+
}
|
|
121
|
+
}) : setTimeout(() => {
|
|
122
|
+
v(n);
|
|
123
|
+
const i = r[n];
|
|
124
|
+
g(i), x(void 0);
|
|
125
|
+
}, 200);
|
|
126
|
+
}
|
|
127
|
+
return l || r;
|
|
128
|
+
}), e));
|
|
129
|
+
}, W = (t) => {
|
|
130
|
+
if (M)
|
|
131
|
+
return T(t).then((e) => {
|
|
132
|
+
e && z((r) => {
|
|
133
|
+
var o;
|
|
134
|
+
let l;
|
|
135
|
+
if (Array.isArray(r)) {
|
|
136
|
+
if (!r.length)
|
|
137
|
+
return S(), r;
|
|
138
|
+
const n = C - 1;
|
|
139
|
+
if (n < 0)
|
|
140
|
+
(c.current - 1) * c.pageSize + n < 0 ? L.error("已经是第一个了") : P({
|
|
141
|
+
current: c.current - 1,
|
|
142
|
+
pageSize: c.pageSize,
|
|
143
|
+
type: "prev"
|
|
144
|
+
});
|
|
145
|
+
else {
|
|
146
|
+
if (f || d) {
|
|
147
|
+
const i = f || d;
|
|
148
|
+
if (i && ((o = i.labels) != null && o.length) && t === 0) {
|
|
149
|
+
const I = r.findIndex((w) => w.id === i.id);
|
|
150
|
+
I > -1 && (r.splice(I, 1), l = [...r]);
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
setTimeout(() => {
|
|
154
|
+
v(n);
|
|
155
|
+
const i = r[n];
|
|
156
|
+
g(i), x(void 0);
|
|
157
|
+
}, 200);
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
return l || r;
|
|
161
|
+
});
|
|
162
|
+
});
|
|
163
|
+
}, T = (t) => {
|
|
164
|
+
var r;
|
|
165
|
+
if (!p)
|
|
166
|
+
return Promise.resolve(!1);
|
|
167
|
+
const e = f || (t === 0 ? d : void 0);
|
|
168
|
+
if (e) {
|
|
169
|
+
if (e.labels)
|
|
170
|
+
e.labels = e.labels.filter((l) => !!l.id);
|
|
171
|
+
else if (t === 0)
|
|
172
|
+
return L.error("图片没有标注信息,无法保存"), Promise.resolve(!1);
|
|
173
|
+
return delete e.confirmStatus, p.updateSamples(s, a, [e], (r = e.labels) != null && r.length ? t : 1).then(() => (L.success({
|
|
174
|
+
content: "保存成功"
|
|
175
|
+
}), z((l) => {
|
|
176
|
+
if (l.length === 0)
|
|
177
|
+
return S(), [];
|
|
178
|
+
{
|
|
179
|
+
const o = l.findIndex((n) => n.id === (e == null ? void 0 : e.id));
|
|
180
|
+
return o > -1 && (l[o] = e), [...l];
|
|
181
|
+
}
|
|
182
|
+
}), !0)).catch(() => !1);
|
|
183
|
+
} else
|
|
184
|
+
return Promise.resolve(!0);
|
|
185
|
+
}, X = () => {
|
|
186
|
+
if (!p)
|
|
187
|
+
return Promise.resolve(!1);
|
|
188
|
+
K.confirm({
|
|
189
|
+
title: "确认要删除当前数据吗?",
|
|
190
|
+
content: "数据包含当前标注的内容和图片,删除后无法恢复,请确认是否删除!",
|
|
191
|
+
onOk: () => {
|
|
192
|
+
d && p.delDatasetsIdVersionsVidSamplesId(s, a, d.id).then(() => {
|
|
193
|
+
const t = u.findIndex((e) => e.id === d.id);
|
|
194
|
+
u.splice(t, 1), z([...u]), u.length || S(), t <= u.length - 1 ? g(u[t]) : (g(u[t - 1]), v(t - 1)), x(void 0), F();
|
|
195
|
+
});
|
|
196
|
+
}
|
|
197
|
+
});
|
|
198
|
+
};
|
|
199
|
+
return /* @__PURE__ */ E(ce, {
|
|
200
|
+
className: "preLabels-details-page",
|
|
201
|
+
header: /* @__PURE__ */ E("div", {
|
|
202
|
+
className: "preLabels-page-header",
|
|
203
|
+
children: [/* @__PURE__ */ m("div", {
|
|
204
|
+
className: "header-title",
|
|
205
|
+
children: "待确认标注"
|
|
206
|
+
}), /* @__PURE__ */ m(V, {
|
|
207
|
+
onClick: S,
|
|
208
|
+
children: "退出"
|
|
209
|
+
})]
|
|
210
|
+
}),
|
|
211
|
+
children: [/* @__PURE__ */ m("div", {
|
|
212
|
+
className: "preLabels-action",
|
|
213
|
+
children: /* @__PURE__ */ E(ne, {
|
|
214
|
+
children: [/* @__PURE__ */ m(V, {
|
|
215
|
+
type: "primary",
|
|
216
|
+
onClick: () => {
|
|
217
|
+
if (f && f.labels.some((t) => !t.id))
|
|
218
|
+
return L.error("所有标注需设置标签"), Promise.resolve(!1);
|
|
219
|
+
x(d), O(0);
|
|
220
|
+
},
|
|
221
|
+
children: "保存当前标注"
|
|
222
|
+
}), /* @__PURE__ */ m(V, {
|
|
223
|
+
onClick: () => {
|
|
224
|
+
if (!p)
|
|
225
|
+
return Promise.resolve(!1);
|
|
226
|
+
K.confirm({
|
|
227
|
+
title: "一键保存所有标注?",
|
|
228
|
+
content: "待确认的所有带预标注信息的图片将保存至已标注页签下",
|
|
229
|
+
onOk: () => {
|
|
230
|
+
p.getAllConfirmSamples(s, a).then((t) => {
|
|
231
|
+
L.success("保存成功"), A(D(y({}, c), {
|
|
232
|
+
current: 1,
|
|
233
|
+
type: "next"
|
|
234
|
+
})).then((e) => {
|
|
235
|
+
Array.isArray(e) && e.length && (v(0), g(e[0]));
|
|
236
|
+
});
|
|
237
|
+
});
|
|
238
|
+
}
|
|
239
|
+
});
|
|
240
|
+
},
|
|
241
|
+
children: "一键保存所有标注"
|
|
242
|
+
}), R && R.delete && /* @__PURE__ */ m(V, {
|
|
243
|
+
onClick: X,
|
|
244
|
+
children: "删除数据"
|
|
245
|
+
})]
|
|
246
|
+
})
|
|
247
|
+
}), /* @__PURE__ */ m("div", {
|
|
248
|
+
className: "d-row",
|
|
249
|
+
children: !!u.length && /* @__PURE__ */ m("div", {
|
|
250
|
+
className: "d-right",
|
|
251
|
+
ref: G,
|
|
252
|
+
children: d && /* @__PURE__ */ m(le, {
|
|
253
|
+
datasetId: s,
|
|
254
|
+
isImageDetailVisible: Q,
|
|
255
|
+
setIsImageDetailVisible: j,
|
|
256
|
+
currentSample: f != null ? f : d,
|
|
257
|
+
labels: q,
|
|
258
|
+
editing: N,
|
|
259
|
+
onChange: x,
|
|
260
|
+
onNextClick: () => O(1),
|
|
261
|
+
onPrevClick: () => W(1),
|
|
262
|
+
onRefresh: () => {
|
|
263
|
+
var t;
|
|
264
|
+
(t = U()) == null || t.then((e) => {
|
|
265
|
+
var r, l;
|
|
266
|
+
if (f) {
|
|
267
|
+
const o = [];
|
|
268
|
+
(r = f.labels) == null || r.forEach((n) => {
|
|
269
|
+
e != null && e.find((i) => i.id === n.id) && o.push(n);
|
|
270
|
+
}), f.labels = o, x(y({}, f));
|
|
271
|
+
}
|
|
272
|
+
if (d) {
|
|
273
|
+
const o = [];
|
|
274
|
+
(l = d.labels) == null || l.forEach((n) => {
|
|
275
|
+
e != null && e.find((i) => i.id === n.id) && o.push(n);
|
|
276
|
+
}), d.labels = o, g(y({}, d));
|
|
277
|
+
}
|
|
278
|
+
});
|
|
279
|
+
},
|
|
280
|
+
settingHide: !0,
|
|
281
|
+
imgCount: {
|
|
282
|
+
total: u.length,
|
|
283
|
+
index: C + 1
|
|
284
|
+
}
|
|
285
|
+
})
|
|
286
|
+
})
|
|
287
|
+
})]
|
|
288
|
+
});
|
|
289
|
+
};
|
|
290
|
+
export {
|
|
291
|
+
be as default
|
|
292
|
+
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { useState as p } from "react";
|
|
3
|
+
import { Tooltip as r } from "antd";
|
|
4
|
+
const f = (t) => {
|
|
5
|
+
const {
|
|
6
|
+
isPreLabel: s,
|
|
7
|
+
placement: i,
|
|
8
|
+
children: l
|
|
9
|
+
} = t, [n, e] = p(!1);
|
|
10
|
+
return /* @__PURE__ */ o(r, {
|
|
11
|
+
title: "预标注进行中,请任务完成后再试",
|
|
12
|
+
open: n,
|
|
13
|
+
placement: i || "top",
|
|
14
|
+
children: /* @__PURE__ */ o("div", {
|
|
15
|
+
onMouseEnter: () => s && e(!0),
|
|
16
|
+
onMouseLeave: () => e(!1),
|
|
17
|
+
children: l
|
|
18
|
+
})
|
|
19
|
+
});
|
|
20
|
+
};
|
|
21
|
+
export {
|
|
22
|
+
f as default
|
|
23
|
+
};
|