@glodon-aiot/dataset-annotation 3.14.0-alpha.32 → 3.14.0-alpha.34
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/es/components/VLMAnnotation/RegionItem.mjs +1 -1
- package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useAIButtonHover.mjs +193 -0
- package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useDrawingMode.mjs +300 -237
- package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useRegionSelection.mjs +158 -56
- package/dist/es/components/VLMAnnotation/VLMLabelMaker/index.mjs +424 -397
- package/dist/es/components/VLMAnnotation/components/AIErrorTooltip/AIErrorTooltip.less.mjs +4 -0
- package/dist/es/components/VLMAnnotation/components/AIErrorTooltip/index.mjs +24 -0
- package/dist/es/components/VLMAnnotation/components/ZoomControls.mjs +1 -1
- package/dist/es/components/VLMAnnotation/constants.mjs +1 -1
- package/dist/es/components/VLMAnnotationDetail/MarkVLMBoxModal/QADetail/QAGenerationConfig.mjs +217 -167
- package/dist/es/components/VLMAnnotationDetail/MarkVLMBoxModal/QADetail/index.mjs +114 -122
- package/dist/es/components/VLMAnnotationDetail/VLMDetail/index.mjs +445 -0
- package/dist/es/components/VLMAnnotationDetail/VlmModal/index.mjs +249 -113
- package/dist/es/components/VLMAnnotationDetail/index.mjs +219 -213
- package/dist/es/index.mjs +1 -1
- package/dist/lib/index.js +4 -4
- package/dist/src/components/VLMAnnotation/VLMLabelMaker/hooks/useAIButtonHover.d.ts +16 -0
- package/dist/src/components/VLMAnnotation/VLMLabelMaker/hooks/useDrawingMode.d.ts +2 -1
- package/dist/src/components/VLMAnnotation/components/AIErrorTooltip/index.d.ts +8 -0
- package/dist/src/components/VLMAnnotation/constants.d.ts +2 -2
- package/dist/src/components/VLMAnnotationDetail/MarkVLMBoxModal/QADetail/QAGenerationConfig.d.ts +1 -0
- package/dist/src/components/VLMAnnotationDetail/VLMDetail/index.d.ts +21 -0
- package/dist/src/components/VLMAnnotationDetail/VlmModal/index.d.ts +11 -2
- package/package.json +2 -2
- package/dist/es/components/VLMAnnotationDetail/MarkVLMBoxModal/index.mjs +0 -455
- /package/dist/es/components/VLMAnnotationDetail/{MarkVLMBoxModal → VLMDetail}/style.less.mjs +0 -0
|
@@ -2,38 +2,37 @@ var Ue = Object.defineProperty, Fe = Object.defineProperties;
|
|
|
2
2
|
var He = Object.getOwnPropertyDescriptors;
|
|
3
3
|
var de = Object.getOwnPropertySymbols;
|
|
4
4
|
var Ke = Object.prototype.hasOwnProperty, Ze = Object.prototype.propertyIsEnumerable;
|
|
5
|
-
var ue = (
|
|
6
|
-
for (var
|
|
7
|
-
Ke.call(
|
|
5
|
+
var ue = (u, o, t) => o in u ? Ue(u, o, { enumerable: !0, configurable: !0, writable: !0, value: t }) : u[o] = t, h = (u, o) => {
|
|
6
|
+
for (var t in o || (o = {}))
|
|
7
|
+
Ke.call(o, t) && ue(u, t, o[t]);
|
|
8
8
|
if (de)
|
|
9
|
-
for (var
|
|
10
|
-
Ze.call(
|
|
11
|
-
return
|
|
12
|
-
}, g = (
|
|
13
|
-
import { jsx as
|
|
14
|
-
import { useState as s, useRef as je, useEffect as
|
|
15
|
-
import { message as
|
|
9
|
+
for (var t of de(o))
|
|
10
|
+
Ze.call(o, t) && ue(u, t, o[t]);
|
|
11
|
+
return u;
|
|
12
|
+
}, g = (u, o) => Fe(u, He(o));
|
|
13
|
+
import { jsx as n, jsxs as S, Fragment as $e } from "react/jsx-runtime";
|
|
14
|
+
import { useState as s, useRef as je, useEffect as d } from "react";
|
|
15
|
+
import { message as q, ConfigProvider as We, Space as P, Select as _e, Button as O, Tabs as qe, Col as Oe, Empty as Ge } from "antd";
|
|
16
16
|
import Je from "antd/es/locale/zh_CN";
|
|
17
17
|
import "./style.less.mjs";
|
|
18
18
|
import Qe from "./VlmModal/index.mjs";
|
|
19
|
-
import Xe from "
|
|
20
|
-
import Ye from "lodash/merge";
|
|
19
|
+
import Xe from "lodash/merge";
|
|
21
20
|
import { UploadZipsStatus as x } from "@glodon-aiot/apis";
|
|
22
|
-
import
|
|
23
|
-
import
|
|
24
|
-
import
|
|
25
|
-
import
|
|
21
|
+
import Ye from "rc-virtual-list";
|
|
22
|
+
import et from "../../Common/Page/index.mjs";
|
|
23
|
+
import tt from "../Thumbnail/index.mjs";
|
|
24
|
+
import rt from "../../DatasetContext/index.mjs";
|
|
26
25
|
import { DEFAULT_FILTER_SWITCH as nt } from "../../constant.mjs";
|
|
27
|
-
import
|
|
26
|
+
import ot from "../PageNav/index.mjs";
|
|
28
27
|
import it from "../PicZipImportModal/index.mjs";
|
|
29
|
-
import { Prompt as
|
|
30
|
-
import
|
|
31
|
-
const
|
|
28
|
+
import { Prompt as lt } from "../hooks/Prompt.mjs";
|
|
29
|
+
import st from "../DetectionAnnotation/icon_item_empty.svg.mjs";
|
|
30
|
+
const xt = (u) => {
|
|
32
31
|
var se;
|
|
33
32
|
const {
|
|
34
|
-
services:
|
|
35
|
-
datasetId:
|
|
36
|
-
versionId:
|
|
33
|
+
services: o,
|
|
34
|
+
datasetId: t,
|
|
35
|
+
versionId: T,
|
|
37
36
|
backTo: fe,
|
|
38
37
|
labelManager: me = !1,
|
|
39
38
|
datasetManager: b = !1,
|
|
@@ -44,76 +43,76 @@ const Tt = (f) => {
|
|
|
44
43
|
exampleSrcRoot: pe,
|
|
45
44
|
apiUrl: ge,
|
|
46
45
|
token: ve
|
|
47
|
-
} =
|
|
46
|
+
} = u, [c, U] = s(), [r, y] = s(), [N, G] = s([]), [J, w] = s(!1), [Se, Q] = s(!1), [z, R] = s(!1), [be, A] = s("preview"), [F, X] = s(0), [f, Ie] = s([]), [H, C] = s(), [ye, Y] = s(), [K, k] = s(-1), [i, V] = s({
|
|
48
47
|
current: 0,
|
|
49
48
|
pageSize: 100
|
|
50
|
-
}), [
|
|
51
|
-
|
|
49
|
+
}), [ee, te] = s(0), [L, Z] = s(""), [I, Ce] = s(""), [ke, Ve] = s(), [De, xe] = s(), [re, $] = s(!1), [ne, Te] = s(!1), [oe, Le] = s(!0), [Me, Ne] = s(!1), B = je(null), j = h({}, nt);
|
|
50
|
+
Xe(j, u.filterSwitch);
|
|
52
51
|
const we = () => {
|
|
53
|
-
|
|
52
|
+
Z("nocode"), A("annotation"), R(!0);
|
|
54
53
|
}, ze = (e) => {
|
|
55
|
-
if (!
|
|
54
|
+
if (!f)
|
|
56
55
|
return;
|
|
57
|
-
|
|
58
|
-
const
|
|
59
|
-
C(
|
|
56
|
+
k(e);
|
|
57
|
+
const l = f[e];
|
|
58
|
+
C(l), A("preview"), R(!0);
|
|
60
59
|
};
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
}, [
|
|
64
|
-
|
|
60
|
+
d(() => {
|
|
61
|
+
o.cvforceDatahub && o.cvforceDatahub.getOptionsImgproxy().then((e) => Ve(e));
|
|
62
|
+
}, [o.cvforceDatahub]), d(() => {
|
|
63
|
+
t && o.cvforceDatahub.getS3Iam(t).then((e) => {
|
|
65
64
|
xe(e);
|
|
66
65
|
});
|
|
67
|
-
}, [
|
|
68
|
-
!
|
|
66
|
+
}, [t]), d(() => {
|
|
67
|
+
!t || r || (w(!0), Promise.all([
|
|
69
68
|
// 数据集
|
|
70
|
-
|
|
71
|
-
|
|
69
|
+
o.cvforceDatahub.getDatasetsId(t).then((e) => {
|
|
70
|
+
U(e);
|
|
72
71
|
}),
|
|
73
72
|
// 版本列表
|
|
74
|
-
|
|
75
|
-
|
|
73
|
+
o.cvforceDatahub.getDatasetsIdVersions(t, 1, 1e3).then((e) => {
|
|
74
|
+
G(e.recordList), y(T ? e.recordList.find((l) => l.id === T) : e.recordList[0]);
|
|
76
75
|
})
|
|
77
|
-
]).finally(() =>
|
|
78
|
-
}, [
|
|
79
|
-
|
|
76
|
+
]).finally(() => w(!1)));
|
|
77
|
+
}, [t, r == null ? void 0 : r.id]), d(() => {
|
|
78
|
+
t && (w(!0), Promise.all([
|
|
80
79
|
// 数据集
|
|
81
|
-
|
|
82
|
-
|
|
80
|
+
o.cvforceDatahub.getDatasetsId(t).then((e) => {
|
|
81
|
+
U(e);
|
|
83
82
|
}),
|
|
84
83
|
// 版本列表
|
|
85
|
-
|
|
86
|
-
|
|
84
|
+
o.cvforceDatahub.getDatasetsIdVersions(t, 1, 1e3).then((e) => {
|
|
85
|
+
G(e.recordList), y(T ? e.recordList.find((l) => l.id === T) : e.recordList[0]);
|
|
87
86
|
})
|
|
88
|
-
]).finally(() =>
|
|
89
|
-
}, [
|
|
90
|
-
|
|
91
|
-
|
|
87
|
+
]).finally(() => w(!1)));
|
|
88
|
+
}, [t, T]), d(() => {
|
|
89
|
+
t && o.cvforceDatahub.getDatasetsId(t).then((e) => {
|
|
90
|
+
U(e);
|
|
92
91
|
});
|
|
93
92
|
}, []);
|
|
94
|
-
const
|
|
95
|
-
!
|
|
96
|
-
|
|
93
|
+
const ie = () => {
|
|
94
|
+
!t || !r || o.cvforceDatahub.getDatasetsIdVersionsVid(t, r.id).then((e) => {
|
|
95
|
+
y(e), Ce(e.versionAsyncTask.state);
|
|
97
96
|
});
|
|
98
97
|
};
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
}, [
|
|
102
|
-
|
|
103
|
-
}, [
|
|
104
|
-
Ne(!
|
|
105
|
-
}, [
|
|
106
|
-
const
|
|
107
|
-
!
|
|
108
|
-
const
|
|
109
|
-
|
|
98
|
+
d(() => {
|
|
99
|
+
ie();
|
|
100
|
+
}, [t, r == null ? void 0 : r.id]), d(() => {
|
|
101
|
+
I !== x.Pending && I !== x.Started || q.warning("文件导入中,请刷新页面再试");
|
|
102
|
+
}, [I]), d(() => {
|
|
103
|
+
Ne(!oe && ne);
|
|
104
|
+
}, [oe, ne]);
|
|
105
|
+
const M = () => {
|
|
106
|
+
!t || !r || o.cvforceDatahub.getDatasetsIdVersionsVidLabelcount(t, r.id).then((e) => {
|
|
107
|
+
const l = e.find((p) => p.id === "allcodeid"), m = e.find((p) => p.id === "nocodeid");
|
|
108
|
+
X(l ? l.count : 0), te(m ? m.count : 0);
|
|
110
109
|
});
|
|
111
|
-
},
|
|
112
|
-
const m = (e == null ? void 0 : e.current) ||
|
|
113
|
-
if (!
|
|
110
|
+
}, D = (e, l) => {
|
|
111
|
+
const m = (e == null ? void 0 : e.current) || i.current, p = (e == null ? void 0 : e.pageSize) || i.pageSize, W = (e == null ? void 0 : e.type) || i.type, _ = l || f || [];
|
|
112
|
+
if (!t || !r || !m)
|
|
114
113
|
return Promise.resolve(!1);
|
|
115
114
|
const Pe = () => {
|
|
116
|
-
switch (
|
|
115
|
+
switch (L) {
|
|
117
116
|
case "nocode":
|
|
118
117
|
return "nocode";
|
|
119
118
|
case "hascode":
|
|
@@ -122,218 +121,218 @@ const Tt = (f) => {
|
|
|
122
121
|
return;
|
|
123
122
|
}
|
|
124
123
|
};
|
|
125
|
-
return m === 1 &&
|
|
124
|
+
return m === 1 && le(), V(g(h({}, i), {
|
|
126
125
|
current: m,
|
|
127
126
|
pageSize: p
|
|
128
|
-
})),
|
|
127
|
+
})), Q(!0), o.cvforceDatahub.getDatasetsIdVersionsVidSamples(t, r.id, {
|
|
129
128
|
pageNo: m,
|
|
130
129
|
pageSize: p,
|
|
131
130
|
labels: Pe()
|
|
132
131
|
}).then((ce) => {
|
|
133
|
-
const v = ce.recordList || [], ae = m === 1 ? v :
|
|
134
|
-
if (
|
|
132
|
+
const v = ce.recordList || [], ae = m === 1 ? v : W === "prev" ? [...v, ..._] : [..._, ...v];
|
|
133
|
+
if (Ie(ae), V(g(h({}, i), {
|
|
135
134
|
current: m,
|
|
136
135
|
pageSize: p,
|
|
137
136
|
type: void 0,
|
|
138
137
|
total: ce.totalResults
|
|
139
|
-
})),
|
|
140
|
-
const
|
|
141
|
-
|
|
138
|
+
})), W === "next" && v.length) {
|
|
139
|
+
const E = _.length;
|
|
140
|
+
k(E), C(v[0]);
|
|
142
141
|
}
|
|
143
|
-
if (
|
|
144
|
-
const
|
|
145
|
-
|
|
142
|
+
if (W === "prev" && v.length) {
|
|
143
|
+
const E = v.length - 1;
|
|
144
|
+
k(E), C(v[E]);
|
|
146
145
|
}
|
|
147
146
|
return ae;
|
|
148
|
-
}).catch(() => !1).finally(() =>
|
|
147
|
+
}).catch(() => !1).finally(() => Q(!1));
|
|
149
148
|
};
|
|
150
|
-
|
|
151
|
-
!
|
|
149
|
+
d(() => {
|
|
150
|
+
!r || !c || (D(g(h({}, i), {
|
|
152
151
|
current: 1
|
|
153
152
|
})).then((e) => {
|
|
154
|
-
}),
|
|
155
|
-
}, [c == null ? void 0 : c.id,
|
|
156
|
-
|
|
157
|
-
}),
|
|
158
|
-
}, [
|
|
159
|
-
|
|
153
|
+
}), M());
|
|
154
|
+
}, [c == null ? void 0 : c.id, r == null ? void 0 : r.id]), d(() => {
|
|
155
|
+
D().then((e) => {
|
|
156
|
+
}), M();
|
|
157
|
+
}, [i.current]), d(() => {
|
|
158
|
+
D(g(h({}, i), {
|
|
160
159
|
current: 1,
|
|
161
160
|
total: void 0
|
|
162
161
|
})).then((e) => {
|
|
163
162
|
});
|
|
164
|
-
}, [
|
|
163
|
+
}, [L]);
|
|
165
164
|
const Re = () => {
|
|
166
|
-
if (!
|
|
165
|
+
if (!f)
|
|
167
166
|
return;
|
|
168
|
-
const e =
|
|
169
|
-
if (e >=
|
|
170
|
-
|
|
171
|
-
current:
|
|
172
|
-
pageSize:
|
|
167
|
+
const e = K + 1;
|
|
168
|
+
if (e >= f.length)
|
|
169
|
+
i.total && e >= i.total ? q.error("已经是最后一个了") : V({
|
|
170
|
+
current: i.current + 1,
|
|
171
|
+
pageSize: i.pageSize,
|
|
173
172
|
type: "next"
|
|
174
173
|
});
|
|
175
174
|
else {
|
|
176
|
-
|
|
177
|
-
const
|
|
178
|
-
C(
|
|
175
|
+
k(e);
|
|
176
|
+
const l = f[e];
|
|
177
|
+
C(l);
|
|
179
178
|
}
|
|
180
179
|
}, Ae = () => {
|
|
181
|
-
if (!
|
|
180
|
+
if (!f)
|
|
182
181
|
return;
|
|
183
|
-
const e =
|
|
182
|
+
const e = K - 1;
|
|
184
183
|
if (e < 0)
|
|
185
|
-
e < 0 ?
|
|
186
|
-
current:
|
|
187
|
-
pageSize:
|
|
184
|
+
e < 0 ? q.error("已经是第一个了") : V({
|
|
185
|
+
current: i.current - 1,
|
|
186
|
+
pageSize: i.pageSize,
|
|
188
187
|
type: "prev"
|
|
189
188
|
});
|
|
190
189
|
else {
|
|
191
|
-
|
|
192
|
-
const
|
|
193
|
-
C(
|
|
190
|
+
k(e);
|
|
191
|
+
const l = f[e];
|
|
192
|
+
C(l);
|
|
194
193
|
}
|
|
195
194
|
}, Be = [{
|
|
196
195
|
key: "",
|
|
197
|
-
label: `全部(${
|
|
196
|
+
label: `全部(${F})`,
|
|
198
197
|
children: null
|
|
199
198
|
}, {
|
|
200
199
|
key: "nocode",
|
|
201
|
-
label: `未标注(${
|
|
200
|
+
label: `未标注(${ee})`,
|
|
202
201
|
children: null
|
|
203
202
|
}, {
|
|
204
203
|
key: "hascode",
|
|
205
|
-
label: `已标注(${
|
|
204
|
+
label: `已标注(${F - ee})`,
|
|
206
205
|
children: null
|
|
207
206
|
}];
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
}, [
|
|
207
|
+
d(() => {
|
|
208
|
+
z || (C(void 0), k(-1), Y(void 0), A("preview"));
|
|
209
|
+
}, [z]), d(() => {
|
|
211
210
|
c && c.markType !== "vlm" && console.error(`当前数据集不是vlm类型,请检查数据集类型。
|
|
212
211
|
请检查markType是否为vlm。`);
|
|
213
212
|
}, [c]);
|
|
214
|
-
const
|
|
215
|
-
var e,
|
|
216
|
-
(
|
|
213
|
+
const le = () => {
|
|
214
|
+
var e, l;
|
|
215
|
+
(l = (e = B.current) == null ? void 0 : e.getElementsByClassName("rc-virtual-list-holder")[0]) == null || l.scrollTo({
|
|
217
216
|
top: 0
|
|
218
217
|
});
|
|
219
218
|
}, Ee = (e) => {
|
|
220
|
-
var
|
|
221
|
-
(!
|
|
222
|
-
current:
|
|
219
|
+
var l;
|
|
220
|
+
(!i.total || i.total > f.length) && e.currentTarget.scrollHeight - e.currentTarget.scrollTop === ((l = B.current) == null ? void 0 : l.clientHeight) && V(g(h({}, i), {
|
|
221
|
+
current: i.current + 1
|
|
223
222
|
}));
|
|
224
223
|
};
|
|
225
|
-
return /* @__PURE__ */
|
|
224
|
+
return /* @__PURE__ */ n(We, {
|
|
226
225
|
locale: Je,
|
|
227
|
-
children: /* @__PURE__ */
|
|
226
|
+
children: /* @__PURE__ */ n(rt.Provider, {
|
|
228
227
|
value: {
|
|
229
|
-
datasetId:
|
|
230
|
-
versionId: (
|
|
231
|
-
no: (
|
|
232
|
-
loading:
|
|
233
|
-
version:
|
|
234
|
-
versions:
|
|
235
|
-
samples:
|
|
236
|
-
pagination:
|
|
237
|
-
services:
|
|
228
|
+
datasetId: t,
|
|
229
|
+
versionId: (r == null ? void 0 : r.id) || "",
|
|
230
|
+
no: (r == null ? void 0 : r.no) || "",
|
|
231
|
+
loading: J,
|
|
232
|
+
version: r,
|
|
233
|
+
versions: N,
|
|
234
|
+
samples: f,
|
|
235
|
+
pagination: i,
|
|
236
|
+
services: o,
|
|
238
237
|
token: ve,
|
|
239
238
|
apiUrl: ge,
|
|
240
239
|
featuresConfig: {
|
|
241
240
|
labelManager: me,
|
|
242
241
|
datasetManager: b,
|
|
243
242
|
annotation: he,
|
|
244
|
-
filterSwitch:
|
|
243
|
+
filterSwitch: j,
|
|
245
244
|
header: a,
|
|
246
245
|
exampleSrcRoot: pe
|
|
247
246
|
}
|
|
248
247
|
},
|
|
249
|
-
children: c ? c.markType === "vlm" ? /* @__PURE__ */
|
|
248
|
+
children: c ? c.markType === "vlm" ? /* @__PURE__ */ S("div", {
|
|
250
249
|
className: "vlm-version-detail",
|
|
251
|
-
children: [/* @__PURE__ */
|
|
250
|
+
children: [/* @__PURE__ */ S(et, {
|
|
252
251
|
className: "product-details-page",
|
|
253
|
-
header: a === !1 ? void 0 : /* @__PURE__ */
|
|
252
|
+
header: a === !1 ? void 0 : /* @__PURE__ */ n(ot, {
|
|
254
253
|
backTo: fe,
|
|
255
254
|
onBackClick: a != null && a.onBackClick ? () => {
|
|
256
255
|
a.onBackClick && a.onBackClick();
|
|
257
256
|
} : void 0,
|
|
258
|
-
left: !
|
|
259
|
-
children: [/* @__PURE__ */
|
|
257
|
+
left: !J && /* @__PURE__ */ S(P, {
|
|
258
|
+
children: [/* @__PURE__ */ n("span", {
|
|
260
259
|
style: {
|
|
261
260
|
fontWeight: "bold"
|
|
262
261
|
},
|
|
263
262
|
children: c == null ? void 0 : c.name
|
|
264
|
-
}), /* @__PURE__ */
|
|
263
|
+
}), /* @__PURE__ */ n(_e, {
|
|
265
264
|
disabled: (a == null ? void 0 : a.versionSelect) === !1,
|
|
266
|
-
value:
|
|
265
|
+
value: r == null ? void 0 : r.id,
|
|
267
266
|
style: {
|
|
268
267
|
width: 70
|
|
269
268
|
},
|
|
270
|
-
options:
|
|
269
|
+
options: N.map((e) => ({
|
|
271
270
|
label: e.no,
|
|
272
271
|
value: e.id
|
|
273
272
|
})),
|
|
274
273
|
onChange: (e) => {
|
|
275
|
-
const
|
|
276
|
-
if (!c || !
|
|
274
|
+
const l = N.find((p) => p.id === e);
|
|
275
|
+
if (!c || !l)
|
|
277
276
|
return;
|
|
278
|
-
const m =
|
|
279
|
-
|
|
277
|
+
const m = N.find((p) => p.id === l.id);
|
|
278
|
+
y(m), a != null && a.onVersionChange && a.onVersionChange(m);
|
|
280
279
|
}
|
|
281
280
|
})]
|
|
282
281
|
}),
|
|
283
|
-
right: /* @__PURE__ */
|
|
284
|
-
children: [!
|
|
282
|
+
right: /* @__PURE__ */ S(P, {
|
|
283
|
+
children: [!H && b && b.add && // <DisabledTooltip
|
|
285
284
|
// isPreLabel={false}
|
|
286
285
|
// placement="bottom"
|
|
287
286
|
// >
|
|
288
|
-
/* @__PURE__ */
|
|
287
|
+
/* @__PURE__ */ n(O, {
|
|
289
288
|
type: "default",
|
|
290
|
-
onClick: () =>
|
|
291
|
-
disabled:
|
|
289
|
+
onClick: () => $(!0),
|
|
290
|
+
disabled: I === x.Pending || I === x.Started,
|
|
292
291
|
children: "导入数据"
|
|
293
|
-
}, "del"), /* @__PURE__ */
|
|
292
|
+
}, "del"), /* @__PURE__ */ n(lt, {
|
|
294
293
|
when: Me,
|
|
295
294
|
content: "确认要离开此页面吗?",
|
|
296
295
|
subContent: "离开此页面后,将结束导入,放弃未上传的文件,请谨慎操作!"
|
|
297
|
-
}), re && /* @__PURE__ */
|
|
296
|
+
}), re && /* @__PURE__ */ n(it, {
|
|
298
297
|
datasetIam: De,
|
|
299
|
-
datasetId:
|
|
300
|
-
currentVersion:
|
|
298
|
+
datasetId: t,
|
|
299
|
+
currentVersion: r,
|
|
301
300
|
tenCode: c == null ? void 0 : c.tenantCode,
|
|
302
301
|
markType: c.markType,
|
|
303
302
|
isVisible: re,
|
|
304
|
-
setIsVisible:
|
|
305
|
-
getVersionListRequest:
|
|
306
|
-
setIsConfirm:
|
|
303
|
+
setIsVisible: $,
|
|
304
|
+
getVersionListRequest: M,
|
|
305
|
+
setIsConfirm: Le,
|
|
307
306
|
onUploadStatusChange: (e) => {
|
|
308
|
-
|
|
307
|
+
Te(e);
|
|
309
308
|
},
|
|
310
309
|
tableReload: () => {
|
|
311
|
-
|
|
310
|
+
r != null && r.id && (le(), D(g(h({}, i), {
|
|
312
311
|
current: 1
|
|
313
312
|
})));
|
|
314
313
|
},
|
|
315
|
-
loadVersionData:
|
|
314
|
+
loadVersionData: ie
|
|
316
315
|
})]
|
|
317
316
|
})
|
|
318
317
|
}),
|
|
319
|
-
children: [/* @__PURE__ */
|
|
318
|
+
children: [/* @__PURE__ */ S("div", {
|
|
320
319
|
className: "vlm-header",
|
|
321
|
-
children: [/* @__PURE__ */
|
|
322
|
-
children:
|
|
320
|
+
children: [/* @__PURE__ */ n(P, {
|
|
321
|
+
children: j.tabs && /* @__PURE__ */ n(qe, {
|
|
323
322
|
className: "header-tab",
|
|
324
|
-
|
|
323
|
+
activeKey: L,
|
|
325
324
|
onChange: (e) => {
|
|
326
|
-
V(g(
|
|
325
|
+
V(g(h({}, i), {
|
|
327
326
|
current: 1
|
|
328
327
|
// total: 0,
|
|
329
|
-
})),
|
|
328
|
+
})), Z(e);
|
|
330
329
|
},
|
|
331
330
|
items: Be
|
|
332
331
|
})
|
|
333
|
-
}), /* @__PURE__ */
|
|
334
|
-
children: b && b.label && /* @__PURE__ */
|
|
332
|
+
}), /* @__PURE__ */ n(P, {
|
|
333
|
+
children: b && b.label && /* @__PURE__ */ n(O, {
|
|
335
334
|
type: "primary",
|
|
336
|
-
disabled: !
|
|
335
|
+
disabled: !F,
|
|
337
336
|
onClick: we,
|
|
338
337
|
style: {
|
|
339
338
|
marginRight: "10px"
|
|
@@ -341,51 +340,56 @@ const Tt = (f) => {
|
|
|
341
340
|
children: "标注"
|
|
342
341
|
})
|
|
343
342
|
})]
|
|
344
|
-
}), /* @__PURE__ */
|
|
343
|
+
}), /* @__PURE__ */ n("div", {
|
|
345
344
|
className: "d-row",
|
|
346
|
-
children: /* @__PURE__ */
|
|
345
|
+
children: /* @__PURE__ */ n("div", {
|
|
347
346
|
className: "d-right",
|
|
348
|
-
ref:
|
|
349
|
-
children:
|
|
350
|
-
children: /* @__PURE__ */
|
|
347
|
+
ref: B,
|
|
348
|
+
children: H ? /* @__PURE__ */ n("div", {}) : i.total !== void 0 && i.total > 0 ? /* @__PURE__ */ n($e, {
|
|
349
|
+
children: /* @__PURE__ */ n(Ye, {
|
|
351
350
|
innerProps: {
|
|
352
351
|
className: "d-right-row"
|
|
353
352
|
},
|
|
354
|
-
data:
|
|
353
|
+
data: f,
|
|
355
354
|
itemKey: "id",
|
|
356
|
-
height: (se =
|
|
355
|
+
height: (se = B.current) == null ? void 0 : se.clientHeight,
|
|
357
356
|
onScroll: Ee,
|
|
358
|
-
children: (e,
|
|
357
|
+
children: (e, l) => /* @__PURE__ */ n(Oe, {
|
|
359
358
|
className: "d-right-col",
|
|
360
|
-
onClick: () => ze(
|
|
361
|
-
children: /* @__PURE__ */
|
|
359
|
+
onClick: () => ze(l),
|
|
360
|
+
children: /* @__PURE__ */ S("div", {
|
|
362
361
|
className: "right-col-wrapper",
|
|
363
|
-
children: /* @__PURE__ */
|
|
362
|
+
children: [/* @__PURE__ */ n("div", {
|
|
364
363
|
className: "right-col-img",
|
|
365
|
-
children: /* @__PURE__ */
|
|
364
|
+
children: /* @__PURE__ */ n(tt, {
|
|
366
365
|
fileKey: e.fileKey,
|
|
367
366
|
width: 124,
|
|
368
|
-
imgProxy:
|
|
367
|
+
imgProxy: ke
|
|
369
368
|
})
|
|
370
|
-
})
|
|
369
|
+
}), /* @__PURE__ */ n("div", {
|
|
370
|
+
className: "right-col-text",
|
|
371
|
+
children: /* @__PURE__ */ n("div", {
|
|
372
|
+
children: l + 1
|
|
373
|
+
})
|
|
374
|
+
})]
|
|
371
375
|
})
|
|
372
376
|
}, e.id)
|
|
373
377
|
})
|
|
374
|
-
}) : /* @__PURE__ */
|
|
378
|
+
}) : /* @__PURE__ */ n("div", {
|
|
375
379
|
className: "empty",
|
|
376
|
-
children:
|
|
377
|
-
image:
|
|
378
|
-
description: /* @__PURE__ */
|
|
379
|
-
children: ["暂无数据",
|
|
380
|
-
children: b && b.add && /* @__PURE__ */
|
|
380
|
+
children: i.total === 0 ? /* @__PURE__ */ n(Ge, {
|
|
381
|
+
image: st,
|
|
382
|
+
description: /* @__PURE__ */ S("span", {
|
|
383
|
+
children: ["暂无数据", L !== "hascode" && /* @__PURE__ */ n("span", {
|
|
384
|
+
children: b && b.add && /* @__PURE__ */ S(O, {
|
|
381
385
|
type: "link",
|
|
382
386
|
size: "small",
|
|
383
387
|
style: {
|
|
384
388
|
padding: 0
|
|
385
389
|
},
|
|
386
|
-
onClick: () =>
|
|
387
|
-
disabled:
|
|
388
|
-
children: [/* @__PURE__ */
|
|
390
|
+
onClick: () => $(!0),
|
|
391
|
+
disabled: I === x.Pending || I === x.Started,
|
|
392
|
+
children: [/* @__PURE__ */ n("span", {
|
|
389
393
|
style: {
|
|
390
394
|
color: "black"
|
|
391
395
|
},
|
|
@@ -398,43 +402,45 @@ const Tt = (f) => {
|
|
|
398
402
|
})
|
|
399
403
|
})
|
|
400
404
|
})]
|
|
401
|
-
}),
|
|
402
|
-
isVlmModalVisible:
|
|
403
|
-
setIsVlmModalVisible:
|
|
404
|
-
record:
|
|
405
|
+
}), z && /* @__PURE__ */ n(Qe, {
|
|
406
|
+
isVlmModalVisible: z,
|
|
407
|
+
setIsVlmModalVisible: R,
|
|
408
|
+
record: H,
|
|
405
409
|
onNextClick: () => Re(),
|
|
406
410
|
onPrevClick: () => Ae(),
|
|
407
|
-
listLoading:
|
|
411
|
+
listLoading: Se,
|
|
408
412
|
ocrMarkTmpl: c == null ? void 0 : c.ocrMarkTmpl,
|
|
409
|
-
datasetId:
|
|
410
|
-
versionId:
|
|
413
|
+
datasetId: t,
|
|
414
|
+
versionId: r == null ? void 0 : r.id,
|
|
415
|
+
initialMode: be,
|
|
416
|
+
filterMode: L,
|
|
417
|
+
onFilterModeChange: (e) => {
|
|
418
|
+
Z(e);
|
|
419
|
+
},
|
|
420
|
+
samples: f,
|
|
421
|
+
pagination: i,
|
|
422
|
+
currentIndex: K,
|
|
411
423
|
handleMarkClick: (e) => {
|
|
412
|
-
|
|
424
|
+
Y(e), A("annotation");
|
|
413
425
|
},
|
|
414
426
|
updateSampleList: () => {
|
|
415
|
-
|
|
427
|
+
D(g(h({}, i), {
|
|
416
428
|
current: 1
|
|
417
|
-
})),
|
|
418
|
-
}
|
|
419
|
-
}), te && (t == null ? void 0 : t.id) && /* @__PURE__ */ o(Xe, {
|
|
420
|
-
visible: te,
|
|
429
|
+
})), M();
|
|
430
|
+
},
|
|
421
431
|
selectSampleId: ye,
|
|
422
|
-
datasetId: r,
|
|
423
|
-
versionId: t.id,
|
|
424
432
|
onClose: () => {
|
|
425
|
-
|
|
433
|
+
D(g(h({}, i), {
|
|
426
434
|
current: 1
|
|
427
|
-
})),
|
|
435
|
+
})), M(), R(!1);
|
|
428
436
|
},
|
|
429
437
|
onSave: (e) => {
|
|
430
|
-
if (!
|
|
438
|
+
if (!t || !r)
|
|
431
439
|
throw "datasetId or version is not exist.";
|
|
432
|
-
return
|
|
433
|
-
current: 1
|
|
434
|
-
})), D(), !0));
|
|
440
|
+
return o.cvforceDatahub.updateSamples(t, r.id, [h({}, e)]).then(() => !0);
|
|
435
441
|
}
|
|
436
442
|
})]
|
|
437
|
-
}) : /* @__PURE__ */
|
|
443
|
+
}) : /* @__PURE__ */ n("div", {
|
|
438
444
|
style: {
|
|
439
445
|
color: "red",
|
|
440
446
|
textAlign: "center"
|
|
@@ -445,5 +451,5 @@ const Tt = (f) => {
|
|
|
445
451
|
});
|
|
446
452
|
};
|
|
447
453
|
export {
|
|
448
|
-
|
|
454
|
+
xt as default
|
|
449
455
|
};
|