@glodon-aiot/dataset-annotation 3.25.1-alpha.6 → 3.26.0-alpha.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/dataset-annotation.js +123598 -0
- package/dist/dataset-annotation.umd.cjs +1017 -0
- package/dist/es/components/OCRImageViewer/index.mjs +117 -130
- package/dist/es/components/OcrAnnotation/OCRBoxDetail/index.mjs +92 -94
- package/dist/es/index.mjs +15 -21
- 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 +4 -37
- package/dist/src/components/OCRImageViewer/index.d.ts +0 -1
- 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/index.d.ts +0 -6
- package/dist/src/utils/reactCompatibility.d.ts +5 -0
- package/package.json +2 -2
- package/dist/es/_virtual/_commonjsHelpers.mjs +0 -8
- package/dist/es/_virtual/dayjs.min.mjs +0 -4
- package/dist/es/components/VersionCompare/VersionCompareSelectModal/index.mjs +0 -122
- package/dist/es/components/VersionCompare/adapter.mjs +0 -215
- package/dist/es/components/VersionCompare/components/DataChangeStatsCard.mjs +0 -68
- package/dist/es/components/VersionCompare/components/DiffValue.mjs +0 -31
- package/dist/es/components/VersionCompare/components/LabelComparisonCard.mjs +0 -130
- package/dist/es/components/VersionCompare/components/ModifiedSampleCompareModal.mjs +0 -207
- package/dist/es/components/VersionCompare/components/SampleChangeDetailsCard.mjs +0 -160
- package/dist/es/components/VersionCompare/components/SingleSampleDetailModal.mjs +0 -165
- package/dist/es/components/VersionCompare/components/VersionCompareHeader.mjs +0 -106
- package/dist/es/components/VersionCompare/components/VersionOverviewCard.mjs +0 -70
- package/dist/es/components/VersionCompare/index.mjs +0 -416
- package/dist/es/components/VersionCompare/mock.mjs +0 -571
- package/dist/es/components/VersionCompare/style.less.mjs +0 -4
- package/dist/es/components/VersionCompare/utils/labelColors.mjs +0 -45
- package/dist/es/createDatasetVersionCompare/index.mjs +0 -124
- package/dist/es/node_modules/dayjs/dayjs.min.mjs +0 -324
- package/dist/src/components/VersionCompare/VersionCompareSelectModal/index.d.ts +0 -16
- package/dist/src/components/VersionCompare/adapter.d.ts +0 -50
- package/dist/src/components/VersionCompare/components/DataChangeStatsCard.d.ts +0 -9
- package/dist/src/components/VersionCompare/components/DiffValue.d.ts +0 -23
- package/dist/src/components/VersionCompare/components/LabelComparisonCard.d.ts +0 -12
- package/dist/src/components/VersionCompare/components/ModifiedSampleCompareModal.d.ts +0 -48
- package/dist/src/components/VersionCompare/components/SampleChangeDetailsCard.d.ts +0 -21
- package/dist/src/components/VersionCompare/components/SingleSampleDetailModal.d.ts +0 -46
- package/dist/src/components/VersionCompare/components/VersionCompareHeader.d.ts +0 -13
- package/dist/src/components/VersionCompare/components/VersionOverviewCard.d.ts +0 -9
- package/dist/src/components/VersionCompare/index.d.ts +0 -34
- package/dist/src/components/VersionCompare/mock.d.ts +0 -25
- package/dist/src/components/VersionCompare/types.d.ts +0 -75
- package/dist/src/components/VersionCompare/utils/labelColors.d.ts +0 -13
- package/dist/src/createDatasetVersionCompare/index.d.ts +0 -26
|
@@ -2,17 +2,17 @@ var Ne = Object.defineProperty, ke = Object.defineProperties;
|
|
|
2
2
|
var we = Object.getOwnPropertyDescriptors;
|
|
3
3
|
var pe = Object.getOwnPropertySymbols;
|
|
4
4
|
var ze = Object.prototype.hasOwnProperty, Le = Object.prototype.propertyIsEnumerable;
|
|
5
|
-
var Ie = (p, u, s) => u in p ? Ne(p, u, { enumerable: !0, configurable: !0, writable: !0, value: s }) : p[u] = s,
|
|
5
|
+
var Ie = (p, u, s) => u in p ? Ne(p, u, { enumerable: !0, configurable: !0, writable: !0, value: s }) : p[u] = s, k = (p, u) => {
|
|
6
6
|
for (var s in u || (u = {}))
|
|
7
7
|
ze.call(u, s) && Ie(p, s, u[s]);
|
|
8
8
|
if (pe)
|
|
9
9
|
for (var s of pe(u))
|
|
10
10
|
Le.call(u, s) && Ie(p, s, u[s]);
|
|
11
11
|
return p;
|
|
12
|
-
},
|
|
13
|
-
import { jsxs as
|
|
14
|
-
import { Tabs as ye, Space as me, Button as K, Tooltip as Pe, Modal as Te, message as
|
|
15
|
-
import { useContext as Oe, useRef as
|
|
12
|
+
}, V = (p, u) => ke(p, we(u));
|
|
13
|
+
import { jsxs as P, Fragment as Ve, jsx as x } from "react/jsx-runtime";
|
|
14
|
+
import { Tabs as ye, Space as me, Button as K, Tooltip as Pe, Modal as Te, message as w } from "antd";
|
|
15
|
+
import { useContext as Oe, useRef as z, useState as I, useEffect as W } from "react";
|
|
16
16
|
import "./style.less.mjs";
|
|
17
17
|
import De from "../../DataEmpty/index.mjs";
|
|
18
18
|
import qe from "../../../DatasetContext/index.mjs";
|
|
@@ -24,8 +24,8 @@ const {
|
|
|
24
24
|
const {
|
|
25
25
|
visible: u,
|
|
26
26
|
selectSampleId: s,
|
|
27
|
-
datasetId:
|
|
28
|
-
versionId:
|
|
27
|
+
datasetId: C,
|
|
28
|
+
versionId: R,
|
|
29
29
|
ocrMarkTmpl: Me,
|
|
30
30
|
onClose: $e,
|
|
31
31
|
onSave: j,
|
|
@@ -42,13 +42,13 @@ const {
|
|
|
42
42
|
services: {
|
|
43
43
|
cvforceDatahub: m
|
|
44
44
|
}
|
|
45
|
-
} = Oe(qe),
|
|
45
|
+
} = Oe(qe), T = z(null), [e, h] = I(), _ = z({}), [je, M] = I(0), [y, B] = I(() => s && (S != null && S.length) ? S : []), [O, N] = I(() => s && U !== void 0 ? U : -1), [d, D] = I(() => s && J ? k({}, J) : !s && J ? {
|
|
46
46
|
current: 1,
|
|
47
47
|
pageSize: J.pageSize
|
|
48
48
|
} : {
|
|
49
49
|
current: 1,
|
|
50
50
|
pageSize: 50
|
|
51
|
-
}), [re, ie] = I(0), [se, oe] = I(0), [ce, le] = I(0), [o, ve] = I(() => s && ne ? ne : s ? "" : "nocode"), de =
|
|
51
|
+
}), [re, ie] = I(0), [se, oe] = I(0), [ce, le] = I(0), [o, ve] = I(() => s && ne ? ne : s ? "" : "nocode"), de = z(!1), ae = z(0), ee = z(0), L = z(!1), $ = z(!1), b = z({}), [E, A] = I(!1), [te, F] = I(!1), Se = () => {
|
|
52
52
|
switch (o) {
|
|
53
53
|
case "nocode":
|
|
54
54
|
case "hascode":
|
|
@@ -71,116 +71,114 @@ const {
|
|
|
71
71
|
}
|
|
72
72
|
};
|
|
73
73
|
W(() => {
|
|
74
|
-
if (!
|
|
75
|
-
|
|
74
|
+
if (!C || !R) {
|
|
75
|
+
L.current = !1;
|
|
76
76
|
return;
|
|
77
77
|
}
|
|
78
|
-
const t = d.current || 1,
|
|
78
|
+
const t = d.current || 1, n = d.pageSize || 50;
|
|
79
79
|
if (!de.current && s && (S != null && S.length) && J && U !== void 0) {
|
|
80
|
-
const c = S.find((
|
|
80
|
+
const c = S.find((r) => r.id === s);
|
|
81
81
|
if (c) {
|
|
82
|
-
de.current = !0, $.current = !0,
|
|
82
|
+
de.current = !0, $.current = !0, L.current = !1, h(c), M(S.length), q();
|
|
83
83
|
return;
|
|
84
84
|
}
|
|
85
85
|
}
|
|
86
86
|
const f = ++ee.current;
|
|
87
|
-
m == null || m.getDatasetsIdVersionsVidSamples(
|
|
87
|
+
m == null || m.getDatasetsIdVersionsVidSamples(C, R, {
|
|
88
88
|
labels: Ce(),
|
|
89
89
|
pageNo: t,
|
|
90
|
-
pageSize:
|
|
90
|
+
pageSize: n,
|
|
91
91
|
confirmStatus: Se()
|
|
92
92
|
}).then((c) => {
|
|
93
93
|
if (f !== ee.current)
|
|
94
94
|
return;
|
|
95
|
-
const
|
|
96
|
-
B(
|
|
97
|
-
const g =
|
|
95
|
+
const r = c.recordList || [];
|
|
96
|
+
B(r);
|
|
97
|
+
const g = V(k({}, d), {
|
|
98
98
|
current: t,
|
|
99
|
-
pageSize:
|
|
99
|
+
pageSize: n,
|
|
100
100
|
total: c.totalResults
|
|
101
101
|
});
|
|
102
102
|
if (delete g.type, D(g), Y == null || Y({
|
|
103
103
|
current: t,
|
|
104
|
-
pageSize:
|
|
104
|
+
pageSize: n,
|
|
105
105
|
total: c.totalResults
|
|
106
|
-
}), d.type === "next" &&
|
|
107
|
-
|
|
106
|
+
}), d.type === "next" && r.length) {
|
|
107
|
+
N(0);
|
|
108
108
|
const l = c.recordList[0];
|
|
109
|
-
h(l), M(
|
|
109
|
+
h(l), M(r.length), o !== void 0 && (b.current[o] = {
|
|
110
110
|
index: 0,
|
|
111
111
|
page: t
|
|
112
112
|
});
|
|
113
113
|
return;
|
|
114
114
|
}
|
|
115
|
-
if (d.type === "prev" &&
|
|
115
|
+
if (d.type === "prev" && r.length) {
|
|
116
116
|
const i = d.pageSize - 1;
|
|
117
|
-
|
|
117
|
+
N(i);
|
|
118
118
|
const l = c.recordList[i];
|
|
119
|
-
h(l), M(
|
|
119
|
+
h(l), M(r.length), o !== void 0 && (b.current[o] = {
|
|
120
120
|
index: i,
|
|
121
121
|
page: t
|
|
122
122
|
});
|
|
123
123
|
return;
|
|
124
124
|
}
|
|
125
|
-
if (
|
|
125
|
+
if (r.find((i) => i.id === s) && !$.current) {
|
|
126
126
|
if (s) {
|
|
127
|
-
$.current = !0, h(
|
|
128
|
-
const i =
|
|
129
|
-
|
|
127
|
+
$.current = !0, h(r.find((l) => l.id === s));
|
|
128
|
+
const i = r.findIndex((l) => l.id === s);
|
|
129
|
+
N(i), o !== void 0 && (b.current[o] = {
|
|
130
130
|
index: i,
|
|
131
131
|
page: t
|
|
132
132
|
});
|
|
133
133
|
} else {
|
|
134
|
-
const i = b.current[o], l = i == null ? void 0 : i.index, a = l !== void 0 && l >= 0 && l <
|
|
135
|
-
h(
|
|
134
|
+
const i = b.current[o], l = i == null ? void 0 : i.index, a = l !== void 0 && l >= 0 && l < r.length ? l : 0;
|
|
135
|
+
h(r[a]), N(a);
|
|
136
136
|
}
|
|
137
|
-
M(
|
|
137
|
+
M(r.length);
|
|
138
138
|
} else if (s && !$.current)
|
|
139
|
-
$.current = !0, m.getDatasetsIdVersionsVidSsamplesSid(
|
|
139
|
+
$.current = !0, m.getDatasetsIdVersionsVidSsamplesSid(C, R, s).then((i) => {
|
|
140
140
|
h(i);
|
|
141
141
|
});
|
|
142
142
|
else {
|
|
143
|
-
const i = b.current[o], l = i == null ? void 0 : i.index, a = l !== void 0 && l >= 0 && l <
|
|
144
|
-
h(
|
|
143
|
+
const i = b.current[o], l = i == null ? void 0 : i.index, a = l !== void 0 && l >= 0 && l < r.length ? l : 0;
|
|
144
|
+
h(r[a]), N(a), M(r.length);
|
|
145
145
|
}
|
|
146
146
|
}).finally(() => {
|
|
147
|
-
f === ee.current && (
|
|
147
|
+
f === ee.current && (L.current = !1);
|
|
148
148
|
}), q();
|
|
149
|
-
}, [d.current, o,
|
|
149
|
+
}, [d.current, o, C, R]), W(() => {
|
|
150
150
|
e != null && e.id && (Z == null || Z(e.id));
|
|
151
151
|
}, [e == null ? void 0 : e.id]);
|
|
152
152
|
const q = () => {
|
|
153
|
-
!
|
|
153
|
+
!C || !R || m == null || m.getDatasetsIdVersionsVidLabelcount(C, R, {
|
|
154
154
|
label: "allcode",
|
|
155
155
|
confirmStatus: 2
|
|
156
156
|
}).then((t) => {
|
|
157
|
-
const
|
|
158
|
-
ie(
|
|
157
|
+
const n = t.find((r) => r.id === "allcodeid"), f = t.find((r) => r.id === "nocodeid"), c = t.find((r) => r.id === "pendingid");
|
|
158
|
+
ie(n ? n.count : 0), oe(f ? f.count : 0), le(c ? c.count : 0);
|
|
159
159
|
});
|
|
160
160
|
}, H = (t) => {
|
|
161
|
-
y && B((
|
|
161
|
+
y && B((n) => {
|
|
162
162
|
var v, i;
|
|
163
|
-
const f = !!(e && ((v = e.labels) != null && v.length && o === "nocode" || !((i = e.labels) != null && i.length) && o === "hascode" || t === !0)), c = f ?
|
|
164
|
-
let
|
|
163
|
+
const f = !!(e && ((v = e.labels) != null && v.length && o === "nocode" || !((i = e.labels) != null && i.length) && o === "hascode" || t === !0)), c = f ? O : O + 1;
|
|
164
|
+
let r = n, g = d.total;
|
|
165
165
|
if (e && f) {
|
|
166
|
-
const l =
|
|
167
|
-
l > -1 && (
|
|
166
|
+
const l = n.findIndex((a) => a.id === e.id);
|
|
167
|
+
l > -1 && (r = n.slice(0, l).concat(n.slice(l + 1)), g && (g = g - 1, D((a) => V(k({}, a), {
|
|
168
168
|
total: g
|
|
169
169
|
}))));
|
|
170
170
|
}
|
|
171
|
-
if (c >=
|
|
172
|
-
if (C.current)
|
|
173
|
-
return n;
|
|
171
|
+
if (c >= r.length) {
|
|
174
172
|
const l = (d.current - 1) * d.pageSize + c;
|
|
175
|
-
g == null || l >= g ? (
|
|
176
|
-
const a =
|
|
177
|
-
|
|
178
|
-
const Re =
|
|
173
|
+
g == null || l >= g ? (r.length > 0 && O >= r.length && setTimeout(() => {
|
|
174
|
+
const a = r.length - 1;
|
|
175
|
+
N(a);
|
|
176
|
+
const Re = r[a];
|
|
179
177
|
h(Re), o !== void 0 && (b.current[o] = {
|
|
180
178
|
index: a,
|
|
181
179
|
page: d.current || 1
|
|
182
180
|
});
|
|
183
|
-
}, 0),
|
|
181
|
+
}, 0), w.error("已经是最后一个了")) : L.current || (L.current = !0, D((a) => V(k({}, a), {
|
|
184
182
|
current: a.current + 1,
|
|
185
183
|
// total 要带上,否则翻页请求回来之前判空会误报“已经是最后一个了”
|
|
186
184
|
total: g,
|
|
@@ -188,36 +186,36 @@ const {
|
|
|
188
186
|
})));
|
|
189
187
|
} else
|
|
190
188
|
setTimeout(() => {
|
|
191
|
-
|
|
192
|
-
const l =
|
|
189
|
+
N(c);
|
|
190
|
+
const l = r[c];
|
|
193
191
|
h(l), o !== void 0 && (b.current[o] = {
|
|
194
192
|
index: c,
|
|
195
193
|
page: d.current || 1
|
|
196
194
|
});
|
|
197
195
|
}, 0);
|
|
198
|
-
return
|
|
196
|
+
return r;
|
|
199
197
|
});
|
|
200
198
|
}, ue = () => {
|
|
201
|
-
var
|
|
202
|
-
if (!y
|
|
199
|
+
var r, g;
|
|
200
|
+
if (!y)
|
|
203
201
|
return;
|
|
204
|
-
let t,
|
|
205
|
-
if (e && y && ((
|
|
202
|
+
let t, n = d.total;
|
|
203
|
+
if (e && y && ((r = e.labels) != null && r.length && o === "nocode" || !((g = e.labels) != null && g.length) && o === "hascode")) {
|
|
206
204
|
const v = y.findIndex((i) => i.id === e.id);
|
|
207
|
-
v > -1 && (t = y.slice(0, v).concat(y.slice(v + 1)),
|
|
208
|
-
total:
|
|
205
|
+
v > -1 && (t = y.slice(0, v).concat(y.slice(v + 1)), n && (n = n - 1, D((i) => V(k({}, i), {
|
|
206
|
+
total: n
|
|
209
207
|
}))));
|
|
210
208
|
}
|
|
211
|
-
const f = t || y, c =
|
|
209
|
+
const f = t || y, c = O - 1;
|
|
212
210
|
if (c < 0)
|
|
213
|
-
(d.current - 1) * d.pageSize + c < 0 ?
|
|
211
|
+
(d.current - 1) * d.pageSize + c < 0 ? w.error("已经是第一个了") : L.current || (L.current = !0, D((i) => V(k({}, i), {
|
|
214
212
|
current: i.current - 1,
|
|
215
213
|
// total 要带上,否则翻页请求回来之前判空会误报“已经是最后一个了”
|
|
216
|
-
total:
|
|
214
|
+
total: n,
|
|
217
215
|
type: "prev"
|
|
218
216
|
})));
|
|
219
217
|
else {
|
|
220
|
-
|
|
218
|
+
N(c);
|
|
221
219
|
const v = f[c];
|
|
222
220
|
h(v), o !== void 0 && (b.current[o] = {
|
|
223
221
|
index: c,
|
|
@@ -227,22 +225,22 @@ const {
|
|
|
227
225
|
t && B(t);
|
|
228
226
|
};
|
|
229
227
|
W(() => {
|
|
230
|
-
if (!u || !
|
|
228
|
+
if (!u || !C || !R || !e)
|
|
231
229
|
return;
|
|
232
230
|
const t = ++ae.current;
|
|
233
|
-
m == null || m.getDatasetsIdVersionsVidSsamplesSid(
|
|
234
|
-
t === ae.current && (h(
|
|
231
|
+
m == null || m.getDatasetsIdVersionsVidSsamplesSid(C, R, e.id).then((n) => {
|
|
232
|
+
t === ae.current && (h(n), _.current = JSON.parse(JSON.stringify(n)));
|
|
235
233
|
});
|
|
236
234
|
}, [e == null ? void 0 : e.id]), W(() => {
|
|
237
|
-
|
|
238
|
-
}, [
|
|
235
|
+
T.current && (T.current.width = T.current.offsetWidth, T.current.height = T.current.offsetHeight);
|
|
236
|
+
}, [T.current]);
|
|
239
237
|
const fe = () => !e || !_.current ? !1 : JSON.stringify(e) !== JSON.stringify(_.current), ge = () => {
|
|
240
238
|
if (e)
|
|
241
239
|
if (fe()) {
|
|
242
240
|
A(!0);
|
|
243
241
|
const t = e.confirmStatus === 1 ? Q : j;
|
|
244
|
-
t == null || t(e).then((
|
|
245
|
-
|
|
242
|
+
t == null || t(e).then((n) => {
|
|
243
|
+
n ? (ue(), q()) : w.error("保存失败");
|
|
246
244
|
}).finally(() => {
|
|
247
245
|
A(!1);
|
|
248
246
|
});
|
|
@@ -253,27 +251,27 @@ const {
|
|
|
253
251
|
if (fe()) {
|
|
254
252
|
A(!0);
|
|
255
253
|
const t = e.confirmStatus === 1 ? Q : j;
|
|
256
|
-
t == null || t(e).then((
|
|
257
|
-
|
|
254
|
+
t == null || t(e).then((n) => {
|
|
255
|
+
n ? (H(), q()) : w.error("保存失败");
|
|
258
256
|
}).finally(() => {
|
|
259
257
|
A(!1);
|
|
260
258
|
});
|
|
261
259
|
} else
|
|
262
260
|
H();
|
|
263
261
|
};
|
|
264
|
-
return /* @__PURE__ */
|
|
265
|
-
children: [/* @__PURE__ */
|
|
262
|
+
return /* @__PURE__ */ P(Ve, {
|
|
263
|
+
children: [/* @__PURE__ */ P("div", {
|
|
266
264
|
className: "ocr-box-detail-records-content",
|
|
267
|
-
children: [/* @__PURE__ */
|
|
265
|
+
children: [/* @__PURE__ */ P(ye, {
|
|
268
266
|
className: "ocr-box-detail-records-content-tabs",
|
|
269
267
|
activeKey: o,
|
|
270
268
|
onChange: (t) => {
|
|
271
|
-
|
|
272
|
-
index:
|
|
269
|
+
O >= 0 && o !== void 0 && o !== null && (b.current[o] = {
|
|
270
|
+
index: O,
|
|
273
271
|
page: d.current || 1
|
|
274
272
|
});
|
|
275
|
-
const
|
|
276
|
-
D(
|
|
273
|
+
const n = b.current[t], f = (n == null ? void 0 : n.page) || 1;
|
|
274
|
+
D(V(k({}, d), {
|
|
277
275
|
current: f
|
|
278
276
|
})), ve(t), X == null || X(t);
|
|
279
277
|
},
|
|
@@ -290,21 +288,21 @@ const {
|
|
|
290
288
|
currentSample: e,
|
|
291
289
|
categories: be,
|
|
292
290
|
onChange: (t) => {
|
|
293
|
-
h(t), B((
|
|
294
|
-
const f =
|
|
295
|
-
return
|
|
291
|
+
h(t), B((n) => {
|
|
292
|
+
const f = n.findIndex((c) => c.id === t.id);
|
|
293
|
+
return n[f] = t, [...n];
|
|
296
294
|
});
|
|
297
295
|
},
|
|
298
296
|
onNextClick: xe,
|
|
299
297
|
onPrevClick: ge
|
|
300
298
|
}) : /* @__PURE__ */ x(De, {})]
|
|
301
|
-
}), /* @__PURE__ */
|
|
299
|
+
}), /* @__PURE__ */ P("div", {
|
|
302
300
|
className: "ocr-box-detail-footer",
|
|
303
301
|
children: [/* @__PURE__ */ x("div", {
|
|
304
302
|
style: {
|
|
305
303
|
width: "420px"
|
|
306
304
|
}
|
|
307
|
-
}), /* @__PURE__ */
|
|
305
|
+
}), /* @__PURE__ */ P(me, {
|
|
308
306
|
children: [/* @__PURE__ */ x(K, {
|
|
309
307
|
type: "default",
|
|
310
308
|
onClick: ge,
|
|
@@ -316,12 +314,12 @@ const {
|
|
|
316
314
|
disabled: E || te,
|
|
317
315
|
children: "下一张"
|
|
318
316
|
}, "next")]
|
|
319
|
-
}), /* @__PURE__ */
|
|
317
|
+
}), /* @__PURE__ */ P(me, {
|
|
320
318
|
style: {
|
|
321
319
|
width: "420px",
|
|
322
320
|
justifyContent: "flex-end"
|
|
323
321
|
},
|
|
324
|
-
children: [/* @__PURE__ */
|
|
322
|
+
children: [/* @__PURE__ */ P("span", {
|
|
325
323
|
className: "ocr-modal-label-num",
|
|
326
324
|
children: ["当前图片标注框数量:", ((he = e == null ? void 0 : e.labels) == null ? void 0 : he.length) || 0]
|
|
327
325
|
}), (e == null ? void 0 : e.confirmStatus) === 1 && /* @__PURE__ */ x(Pe, {
|
|
@@ -340,7 +338,7 @@ const {
|
|
|
340
338
|
content: "是否确认当前标注?",
|
|
341
339
|
onOk: () => {
|
|
342
340
|
e && (F(!0), j(e).then((t) => {
|
|
343
|
-
t ? (
|
|
341
|
+
t ? (w.success("保存成功"), H(!0), q()) : w.error("保存失败");
|
|
344
342
|
}).finally(() => {
|
|
345
343
|
F(!1);
|
|
346
344
|
}));
|
|
@@ -360,8 +358,8 @@ const {
|
|
|
360
358
|
return;
|
|
361
359
|
F(!0);
|
|
362
360
|
const t = e.confirmStatus === 1 ? Q : j;
|
|
363
|
-
t == null || t(e).then((
|
|
364
|
-
|
|
361
|
+
t == null || t(e).then((n) => {
|
|
362
|
+
n ? (w.success("保存成功"), H(), q()) : w.error("保存失败");
|
|
365
363
|
}).finally(() => {
|
|
366
364
|
F(!1);
|
|
367
365
|
});
|