@glodon-aiot/dataset-annotation 3.10.0-alpha.18 → 3.10.0-snapshot.16
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/dataset-annotation.js +123598 -0
- package/dist/dataset-annotation.umd.cjs +1017 -0
- package/dist/es/components/DetectionAnnotation/components/LabelMaker/Drawable.mjs +28 -37
- package/dist/es/components/OcrAnnotation/MarkKVOCRModal/KVOCRLabelMaker/index.mjs +1 -1
- package/dist/es/components/OcrAnnotation/MarkOCRBoxModal/OCRBoxMaker/index.mjs +1 -1
- package/dist/es/components/OcrAnnotation/OcrModal/index.mjs +45 -43
- package/dist/es/components/PicZipImportModal/index.mjs +220 -219
- package/dist/es/components/VLMAnnotationDetail/MarkVLMBoxModal/AttributeDetail/index.mjs +21 -19
- package/dist/es/components/VLMAnnotationDetail/MarkVLMBoxModal/QADetail/index.mjs +43 -43
- package/dist/es/components/VLMAnnotationDetail/MarkVLMBoxModal/index.mjs +230 -247
- package/dist/es/components/VLMAnnotationDetail/VlmModal/index.mjs +64 -68
- package/dist/es/components/VLMAnnotationDetail/index.mjs +174 -177
- package/dist/es/index.mjs +1 -1
- package/dist/example/DatasetAnnotationDemo.d.ts +3 -0
- package/dist/example/DemoTabs.d.ts +3 -0
- package/dist/example/DetectionDatasetDemo.d.ts +5 -0
- package/dist/example/DetectionImageDemo.d.ts +5 -0
- package/dist/example/OcrDatasetDemo.d.ts +5 -0
- package/dist/example/OcrImageDemo.d.ts +5 -0
- package/dist/example/OcrkvcDatasetDemo.d.ts +5 -0
- package/dist/example/constant.local.d.ts +6 -0
- package/dist/example/index.d.ts +1 -0
- package/dist/lib/index.js +3 -3
- package/dist/src/components/VLMAnnotationDetail/MarkVLMBoxModal/ImageDetail/index.d.ts +16 -0
- package/dist/src/components/VLMAnnotationDetail/MarkVLMBoxModal/OCRBoxMaker/LabelEditorInput.d.ts +12 -0
- package/dist/src/components/VLMAnnotationDetail/MarkVLMBoxModal/OCRBoxMaker/LabelEditorItem.d.ts +21 -0
- package/dist/src/components/VLMAnnotationDetail/MarkVLMBoxModal/OCRBoxMaker/LableEditor.d.ts +16 -0
- package/dist/src/components/VLMAnnotationDetail/MarkVLMBoxModal/OCRBoxMaker/index.d.ts +19 -0
- package/dist/src/utils/reactCompatibility.d.ts +5 -0
- package/package.json +8 -5
|
@@ -1,45 +1,44 @@
|
|
|
1
|
-
var k = (
|
|
2
|
-
var m = (
|
|
1
|
+
var k = (h, r, a) => new Promise((c, o) => {
|
|
2
|
+
var m = (l) => {
|
|
3
3
|
try {
|
|
4
|
-
s(
|
|
4
|
+
s(a.next(l));
|
|
5
5
|
} catch (d) {
|
|
6
|
-
|
|
6
|
+
o(d);
|
|
7
7
|
}
|
|
8
|
-
},
|
|
8
|
+
}, i = (l) => {
|
|
9
9
|
try {
|
|
10
|
-
s(
|
|
10
|
+
s(a.throw(l));
|
|
11
11
|
} catch (d) {
|
|
12
|
-
|
|
12
|
+
o(d);
|
|
13
13
|
}
|
|
14
|
-
}, s = (
|
|
15
|
-
s((
|
|
14
|
+
}, s = (l) => l.done ? c(l.value) : Promise.resolve(l.value).then(m, i);
|
|
15
|
+
s((a = a.apply(h, r)).next());
|
|
16
16
|
});
|
|
17
|
-
import { jsxs as
|
|
18
|
-
import { useRef as
|
|
19
|
-
import { Modal as
|
|
17
|
+
import { jsxs as p, jsx as e } from "react/jsx-runtime";
|
|
18
|
+
import { useRef as v, useState as u, useContext as R, useEffect as O } from "react";
|
|
19
|
+
import { Modal as N, Button as f, Space as b, message as g } from "antd";
|
|
20
20
|
import "./style.less.mjs";
|
|
21
21
|
import { useKeyPress as M } from "ahooks";
|
|
22
|
-
import
|
|
23
|
-
import
|
|
24
|
-
|
|
25
|
-
const G = (f) => {
|
|
22
|
+
import j from "../../../DatasetContext/index.mjs";
|
|
23
|
+
import D from "../../VLMAnnotation/index.mjs";
|
|
24
|
+
const q = (h) => {
|
|
26
25
|
const {
|
|
27
|
-
isVlmModalVisible:
|
|
28
|
-
setIsVlmModalVisible:
|
|
26
|
+
isVlmModalVisible: r,
|
|
27
|
+
setIsVlmModalVisible: a,
|
|
29
28
|
record: c,
|
|
30
|
-
onNextClick:
|
|
29
|
+
onNextClick: o,
|
|
31
30
|
onPrevClick: m,
|
|
32
|
-
datasetId:
|
|
31
|
+
datasetId: i,
|
|
33
32
|
versionId: s,
|
|
34
|
-
ocrMarkTmpl:
|
|
33
|
+
ocrMarkTmpl: l,
|
|
35
34
|
handleMarkClick: d,
|
|
36
35
|
updateSampleList: V
|
|
37
|
-
} =
|
|
38
|
-
|
|
39
|
-
const
|
|
40
|
-
|
|
41
|
-
const [t,
|
|
42
|
-
|
|
36
|
+
} = h;
|
|
37
|
+
v(null);
|
|
38
|
+
const y = v({});
|
|
39
|
+
u("annotation");
|
|
40
|
+
const [t, x] = u();
|
|
41
|
+
u();
|
|
43
42
|
const {
|
|
44
43
|
services: {
|
|
45
44
|
cvforceDatahub: n
|
|
@@ -49,60 +48,64 @@ const G = (f) => {
|
|
|
49
48
|
} = {
|
|
50
49
|
datasetManager: !1
|
|
51
50
|
}
|
|
52
|
-
} = R(
|
|
51
|
+
} = R(j);
|
|
53
52
|
M("rightarrow", () => {
|
|
54
|
-
|
|
53
|
+
o();
|
|
55
54
|
}), M("leftarrow", () => {
|
|
56
55
|
m();
|
|
57
56
|
}), O(() => {
|
|
58
|
-
|
|
59
|
-
|
|
57
|
+
r && i && s && (n == null || n.getDatasetsIdVersionsVidSsamplesSid(i, s, c.id).then((S) => {
|
|
58
|
+
x(S);
|
|
60
59
|
}));
|
|
61
|
-
}, [
|
|
62
|
-
const
|
|
63
|
-
|
|
64
|
-
},
|
|
65
|
-
|
|
60
|
+
}, [r, c]);
|
|
61
|
+
const I = () => {
|
|
62
|
+
a(!1);
|
|
63
|
+
}, w = () => {
|
|
64
|
+
N.confirm({
|
|
66
65
|
title: "确认要删除此数据吗?",
|
|
67
66
|
content: "删除后不可恢复,请慎重操作",
|
|
68
67
|
onOk: () => {
|
|
69
|
-
!
|
|
70
|
-
g.success("删除成功"),
|
|
68
|
+
!i || !s || !(t != null && t.id) || n == null || n.delDatasetsIdVersionsVidSamplesId(i, s, t.id).then(() => {
|
|
69
|
+
g.success("删除成功"), a(!1), V();
|
|
71
70
|
}).catch(() => g.error("删除失败"));
|
|
72
71
|
}
|
|
73
72
|
});
|
|
74
73
|
};
|
|
75
|
-
return /* @__PURE__ */
|
|
76
|
-
title: /* @__PURE__ */
|
|
74
|
+
return /* @__PURE__ */ p(N, {
|
|
75
|
+
title: /* @__PURE__ */ p("div", {
|
|
77
76
|
className: "vlm-sample-detail-title",
|
|
78
|
-
children: /* @__PURE__ */ e("span", {
|
|
77
|
+
children: [/* @__PURE__ */ e("span", {
|
|
79
78
|
children: "详情"
|
|
80
|
-
})
|
|
79
|
+
}), /* @__PURE__ */ p("div", {
|
|
80
|
+
className: "title-buttons",
|
|
81
|
+
children: [/* @__PURE__ */ e(f, {
|
|
82
|
+
className: "select-prev",
|
|
83
|
+
onClick: () => m(),
|
|
84
|
+
children: "上一张"
|
|
85
|
+
}), /* @__PURE__ */ e(f, {
|
|
86
|
+
className: "select-next",
|
|
87
|
+
onClick: () => o(),
|
|
88
|
+
children: "下一张"
|
|
89
|
+
})]
|
|
90
|
+
})]
|
|
81
91
|
}),
|
|
82
92
|
width: "100%",
|
|
83
93
|
wrapClassName: "vlm-modal-wrap",
|
|
84
94
|
className: "vlm-modal",
|
|
85
|
-
open:
|
|
95
|
+
open: r,
|
|
86
96
|
destroyOnClose: !0,
|
|
87
|
-
onCancel: () =>
|
|
97
|
+
onCancel: () => I(),
|
|
88
98
|
maskClosable: !1,
|
|
89
99
|
centered: !0,
|
|
90
100
|
footer: null,
|
|
91
101
|
children: [/* @__PURE__ */ e("div", {
|
|
92
102
|
className: "vlm-detail",
|
|
93
|
-
children: /* @__PURE__ */
|
|
103
|
+
children: /* @__PURE__ */ e("div", {
|
|
94
104
|
className: "detail-content",
|
|
95
|
-
children:
|
|
96
|
-
className: "select-prev",
|
|
97
|
-
icon: /* @__PURE__ */ e(N, {
|
|
98
|
-
type: "icon-zuojiantou"
|
|
99
|
-
}),
|
|
100
|
-
type: "text",
|
|
101
|
-
onClick: () => m()
|
|
102
|
-
}), /* @__PURE__ */ e("div", {
|
|
105
|
+
children: /* @__PURE__ */ e("div", {
|
|
103
106
|
className: "select-main",
|
|
104
|
-
ref:
|
|
105
|
-
children: t && /* @__PURE__ */ e(
|
|
107
|
+
ref: y,
|
|
108
|
+
children: t && /* @__PURE__ */ e(D, {
|
|
106
109
|
sample: t,
|
|
107
110
|
labelDefinitions: [],
|
|
108
111
|
hideRightSide: !0,
|
|
@@ -112,26 +115,19 @@ const G = (f) => {
|
|
|
112
115
|
}),
|
|
113
116
|
coordinateType: "center"
|
|
114
117
|
})
|
|
115
|
-
})
|
|
116
|
-
className: "select-next",
|
|
117
|
-
icon: /* @__PURE__ */ e(N, {
|
|
118
|
-
type: "icon-youjiantou"
|
|
119
|
-
}),
|
|
120
|
-
type: "text",
|
|
121
|
-
onClick: () => r()
|
|
122
|
-
})]
|
|
118
|
+
})
|
|
123
119
|
})
|
|
124
120
|
}), /* @__PURE__ */ e("div", {
|
|
125
121
|
className: "vlm-mark-action",
|
|
126
|
-
children: /* @__PURE__ */
|
|
127
|
-
children: [/* @__PURE__ */ e(
|
|
122
|
+
children: /* @__PURE__ */ p(b, {
|
|
123
|
+
children: [/* @__PURE__ */ e(f, {
|
|
128
124
|
type: "primary",
|
|
129
125
|
onClick: () => d(t == null ? void 0 : t.id),
|
|
130
126
|
children: "标注"
|
|
131
|
-
}), C && C.delete && /* @__PURE__ */ e(
|
|
127
|
+
}), C && C.delete && /* @__PURE__ */ e(f, {
|
|
132
128
|
danger: !0,
|
|
133
129
|
type: "ghost",
|
|
134
|
-
onClick:
|
|
130
|
+
onClick: w,
|
|
135
131
|
children: "删除数据"
|
|
136
132
|
})]
|
|
137
133
|
})
|
|
@@ -139,5 +135,5 @@ const G = (f) => {
|
|
|
139
135
|
});
|
|
140
136
|
};
|
|
141
137
|
export {
|
|
142
|
-
|
|
138
|
+
q as default
|
|
143
139
|
};
|