@glodon-aiot/dataset-annotation 3.13.0-alpha.29 → 3.14.0-alpha.31

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.
Files changed (33) hide show
  1. package/dist/es/components/DetectionAnnotation/components/LabelMaker/RectLabel.mjs +151 -135
  2. package/dist/es/components/DetectionAnnotation/components/LabelMaker/index.mjs +244 -218
  3. package/dist/es/components/VLMAnnotation/RegionItem.mjs +135 -59
  4. package/dist/es/components/VLMAnnotation/TextAnnotationPanel.mjs +73 -62
  5. package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useDeleteRegion.mjs +55 -40
  6. package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useDrawingMode.mjs +291 -162
  7. package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useOCRControl.mjs +100 -0
  8. package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useOCRRecognition.mjs +88 -55
  9. package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useRegionBoundaryCheck.mjs +103 -0
  10. package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useRegionLoader.mjs +123 -91
  11. package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useRegionSelection.mjs +42 -39
  12. package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useRegionUpdate.mjs +55 -60
  13. package/dist/es/components/VLMAnnotation/VLMLabelMaker/icons/ai.svg.mjs +4 -0
  14. package/dist/es/components/VLMAnnotation/VLMLabelMaker/icons/error.svg.mjs +4 -0
  15. package/dist/es/components/VLMAnnotation/VLMLabelMaker/icons/loading.svg.mjs +4 -0
  16. package/dist/es/components/VLMAnnotation/VLMLabelMaker/icons/star.svg.mjs +4 -0
  17. package/dist/es/components/VLMAnnotation/VLMLabelMaker/index.mjs +512 -387
  18. package/dist/es/components/VLMAnnotation/constants.mjs +39 -32
  19. package/dist/es/components/VLMAnnotation/index.mjs +187 -150
  20. package/dist/es/index.mjs +1 -1
  21. package/dist/lib/index.js +4 -4
  22. package/dist/src/components/VLMAnnotation/VLMLabelMaker/hooks/useDeleteRegion.d.ts +1 -0
  23. package/dist/src/components/VLMAnnotation/VLMLabelMaker/hooks/useDrawingMode.d.ts +3 -1
  24. package/dist/src/components/VLMAnnotation/VLMLabelMaker/hooks/useOCRControl.d.ts +16 -0
  25. package/dist/src/components/VLMAnnotation/VLMLabelMaker/hooks/useOCRRecognition.d.ts +3 -2
  26. package/dist/src/components/VLMAnnotation/VLMLabelMaker/hooks/useRegionBoundaryCheck.d.ts +31 -0
  27. package/dist/src/components/VLMAnnotation/VLMLabelMaker/hooks/useRegionLoader.d.ts +5 -1
  28. package/dist/src/components/VLMAnnotation/VLMLabelMaker/hooks/useRegionSelection.d.ts +2 -1
  29. package/dist/src/components/VLMAnnotation/VLMLabelMaker/index.d.ts +2 -2
  30. package/dist/src/components/VLMAnnotation/constants.d.ts +19 -3
  31. package/dist/src/components/VLMAnnotation/index.d.ts +1 -1
  32. package/dist/src/components/VLMAnnotation/types.d.ts +15 -0
  33. package/package.json +2 -2
@@ -1,94 +1,170 @@
1
- import { jsxs as x, jsx as c } from "react/jsx-runtime";
2
- import { useRef as w, useState as I, useEffect as v } from "react";
3
- import { Input as T } from "antd";
4
- import { UpOutlined as j } from "@ant-design/icons";
5
- const M = ({
6
- name: h,
7
- labelDefinitions: m,
8
- region: $,
9
- isSelected: p,
10
- isActive: s,
11
- activeLabelId: i,
12
- onChange: a,
13
- onFocus: f,
14
- onBlur: d,
15
- readOnly: N
1
+ import { jsxs as i, jsx as e } from "react/jsx-runtime";
2
+ import { useRef as U, useState as k, useEffect as $ } from "react";
3
+ import { Tooltip as V, Input as W } from "antd";
4
+ import { UpOutlined as q } from "@ant-design/icons";
5
+ import G from "./VLMLabelMaker/icons/del.png.mjs";
6
+ import H from "./VLMLabelMaker/icons/ai.svg.mjs";
7
+ import J from "./VLMLabelMaker/icons/star.svg.mjs";
8
+ import K from "./VLMLabelMaker/icons/loading.svg.mjs";
9
+ const F = ({
10
+ name: P,
11
+ labelDefinitions: v,
12
+ region: m,
13
+ isSelected: g,
14
+ isActive: l,
15
+ activeLabelId: a,
16
+ onChange: x,
17
+ onFocus: h,
18
+ onBlur: N,
19
+ onDelete: T,
20
+ onRegionClick: c,
21
+ onOCR: M,
22
+ isOCRRecognizing: p,
23
+ hasOCRError: w,
24
+ readOnly: d
16
25
  }) => {
17
- const n = w(null), u = w(/* @__PURE__ */ new Map()), [l, g] = I(!1);
18
- return v(() => {
19
- p && n.current && (g(!1), setTimeout(() => {
26
+ const n = U(null), u = U(/* @__PURE__ */ new Map()), [f, I] = k(!1);
27
+ return $(() => {
28
+ g && n.current && (I(!1), setTimeout(() => {
20
29
  n.current && n.current.scrollIntoView({
21
30
  behavior: "smooth",
22
31
  block: "nearest",
23
32
  inline: "nearest"
24
33
  });
25
34
  }, 200));
26
- }, [p]), v(() => {
27
- s && n.current && (g(!1), setTimeout(() => {
35
+ }, [g]), $(() => {
36
+ l && n.current && (I(!1), setTimeout(() => {
28
37
  n.current && n.current.scrollIntoView({
29
38
  behavior: "smooth",
30
39
  block: "nearest",
31
40
  inline: "nearest"
32
41
  });
33
42
  }, 200));
34
- }, [s]), v(() => {
35
- if (s && i) {
36
- const t = u.current.get(i);
43
+ }, [l]), $(() => {
44
+ if (l && a) {
45
+ const t = u.current.get(a);
37
46
  t != null && t.input ? t.input.focus() : setTimeout(() => {
38
- const o = u.current.get(i);
39
- o != null && o.input && o.input.focus();
47
+ const r = u.current.get(a);
48
+ r != null && r.input && r.input.focus();
40
49
  }, 100);
41
50
  }
42
- }, [s, i]), /* @__PURE__ */ x("div", {
51
+ }, [l, a]), /* @__PURE__ */ i("div", {
43
52
  ref: n,
44
- className: `vlm-text-region ${p || s ? "vlm-text-region-selected" : ""} ${l ? "vlm-text-region-collapsed" : ""}`,
45
- children: [/* @__PURE__ */ x("div", {
53
+ className: `vlm-text-region ${g || l ? "vlm-text-region-selected" : ""} ${f ? "vlm-text-region-collapsed" : ""}`,
54
+ children: [/* @__PURE__ */ i("div", {
46
55
  className: "vlm-text-region-header",
47
- onClick: () => g(!l),
48
- children: [/* @__PURE__ */ c("span", {
49
- className: `vlm-text-region-collapse-icon ${l ? "vlm-text-region-collapse-icon-collapsed" : ""}`,
50
- children: /* @__PURE__ */ c(j, {})
51
- }), /* @__PURE__ */ c("span", {
56
+ onClick: (t) => {
57
+ const r = t.target;
58
+ r.closest(".vlm-text-region-delete-btn") !== null || r.closest(".vlm-text-region-collapse-icon") !== null || c == null || c(m);
59
+ },
60
+ children: [/* @__PURE__ */ e("span", {
61
+ className: `vlm-text-region-collapse-icon ${f ? "vlm-text-region-collapse-icon-collapsed" : ""}`,
62
+ onClick: (t) => {
63
+ t.stopPropagation(), I(!f);
64
+ },
65
+ children: /* @__PURE__ */ e(q, {})
66
+ }), /* @__PURE__ */ e("span", {
52
67
  className: "vlm-text-region-name",
53
- children: h
68
+ children: P
69
+ }), /* @__PURE__ */ i("div", {
70
+ className: "vlm-text-region-actions",
71
+ children: [!d && M && /* @__PURE__ */ e(V, {
72
+ title: p ? "识别中..." : w ? "识别失败,点击重试" : "OCR识别",
73
+ children: /* @__PURE__ */ e("span", {
74
+ className: `vlm-text-region-ocr-btn ${p ? "vlm-text-region-ocr-btn-loading" : ""} ${w ? "vlm-text-region-ocr-btn-error" : ""}`,
75
+ onClick: (t) => {
76
+ t.stopPropagation(), p || M(m.id);
77
+ },
78
+ children: /* @__PURE__ */ i("div", {
79
+ className: "vlm-text-region-ocr-icon-wrapper",
80
+ children: [/* @__PURE__ */ e("img", {
81
+ src: H,
82
+ alt: "OCR识别",
83
+ className: "vlm-text-region-ocr-icon"
84
+ }), p ? /* @__PURE__ */ e("img", {
85
+ src: K,
86
+ alt: "",
87
+ className: "vlm-text-region-ocr-status vlm-text-region-ocr-loading"
88
+ }) : w ? /* @__PURE__ */ i("svg", {
89
+ className: "vlm-text-region-ocr-status vlm-text-region-ocr-error-icon",
90
+ width: "12",
91
+ height: "12",
92
+ viewBox: "0 0 12 12",
93
+ fill: "none",
94
+ xmlns: "http://www.w3.org/2000/svg",
95
+ children: [/* @__PURE__ */ e("circle", {
96
+ cx: "6",
97
+ cy: "6",
98
+ r: "5.5",
99
+ fill: "#ff4d4f",
100
+ stroke: "none"
101
+ }), /* @__PURE__ */ e("path", {
102
+ d: "M6 3.5v3M6 8.5h.01",
103
+ stroke: "#fff",
104
+ strokeWidth: "1.2",
105
+ strokeLinecap: "round"
106
+ })]
107
+ }) : /* @__PURE__ */ e("img", {
108
+ src: J,
109
+ alt: "",
110
+ className: "vlm-text-region-ocr-status vlm-text-region-ocr-star"
111
+ })]
112
+ })
113
+ })
114
+ }), !d && T && /* @__PURE__ */ e("span", {
115
+ className: "vlm-text-region-delete-btn",
116
+ onClick: (t) => {
117
+ t.stopPropagation(), T(m.id);
118
+ },
119
+ title: "删除",
120
+ children: /* @__PURE__ */ e("img", {
121
+ src: G,
122
+ alt: "删除",
123
+ className: "vlm-text-region-delete-icon"
124
+ })
125
+ })]
54
126
  })]
55
- }), /* @__PURE__ */ c("div", {
56
- className: `vlm-text-region-content ${l ? "vlm-text-region-content-collapsed" : ""}`,
57
- children: m == null ? void 0 : m.map((t) => {
58
- const o = s && i === t.id;
59
- return /* @__PURE__ */ x("div", {
127
+ }), /* @__PURE__ */ e("div", {
128
+ className: `vlm-text-region-content ${f ? "vlm-text-region-content-collapsed" : ""}`,
129
+ onClick: (t) => {
130
+ const r = t.target;
131
+ r.tagName === "INPUT" || r.closest("input") !== null || c == null || c(m);
132
+ },
133
+ children: v == null ? void 0 : v.map((t) => {
134
+ const r = l && a === t.id;
135
+ return /* @__PURE__ */ i("div", {
60
136
  className: "vlm-text-label",
61
- children: [t.name, /* @__PURE__ */ c("br", {}), /* @__PURE__ */ c(T, {
62
- ref: (e) => {
63
- e ? u.current.set(t.id, e) : u.current.delete(t.id);
137
+ children: [t.name, /* @__PURE__ */ e("br", {}), /* @__PURE__ */ e(W, {
138
+ ref: (o) => {
139
+ o ? u.current.set(t.id, o) : u.current.delete(t.id);
64
140
  },
65
- value: $.content[t.id],
66
- onFocus: (e) => {
67
- f == null || f(t.id, e.target.value || ""), setTimeout(() => {
68
- const r = u.current.get(t.id);
69
- r != null && r.input && r.input.focus();
141
+ value: m.content[t.id],
142
+ onFocus: (o) => {
143
+ h == null || h(t.id, o.target.value || ""), setTimeout(() => {
144
+ const s = u.current.get(t.id);
145
+ s != null && s.input && s.input.focus();
70
146
  }, 0);
71
147
  },
72
- onBlur: (e) => {
73
- console.log("onBlur", e);
74
- const r = e.relatedTarget, k = (r == null ? void 0 : r.tagName) === "INPUT" || (r == null ? void 0 : r.closest("input")) !== null;
75
- if (o && !k) {
76
- e.target.focus();
148
+ onBlur: (o) => {
149
+ console.log("onBlur", o);
150
+ const s = o.relatedTarget, j = (s == null ? void 0 : s.tagName) === "INPUT" || (s == null ? void 0 : s.closest("input")) !== null;
151
+ if (r && !j) {
152
+ o.target.focus();
77
153
  return;
78
154
  }
79
- d == null || d(t.id, e.target.value || "");
155
+ N == null || N(t.id, o.target.value || "");
80
156
  },
81
- onChange: (e) => {
82
- a == null || a(t.id, e.target.value || "");
157
+ onChange: (o) => {
158
+ x == null || x(t.id, o.target.value || "");
83
159
  },
84
- allowClear: !N,
85
- readOnly: N
160
+ allowClear: !d,
161
+ readOnly: d
86
162
  })]
87
163
  }, t.id);
88
164
  })
89
165
  })]
90
- }, h);
166
+ }, P);
91
167
  };
92
168
  export {
93
- M as default
169
+ F as default
94
170
  };
@@ -1,83 +1,94 @@
1
- var S = Object.defineProperty, T = Object.defineProperties;
2
- var X = Object.getOwnPropertyDescriptors;
3
- var j = Object.getOwnPropertySymbols;
4
- var k = Object.prototype.hasOwnProperty, q = Object.prototype.propertyIsEnumerable;
5
- var G = (r, m, t) => m in r ? S(r, m, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[m] = t, E = (r, m) => {
6
- for (var t in m || (m = {}))
7
- k.call(m, t) && G(r, t, m[t]);
8
- if (j)
9
- for (var t of j(m))
10
- q.call(m, t) && G(r, t, m[t]);
11
- return r;
12
- }, I = (r, m) => T(r, X(m));
1
+ var B = Object.defineProperty, H = Object.defineProperties;
2
+ var J = Object.getOwnPropertyDescriptors;
3
+ var S = Object.getOwnPropertySymbols;
4
+ var K = Object.prototype.hasOwnProperty, Q = Object.prototype.propertyIsEnumerable;
5
+ var T = (m, d, t) => d in m ? B(m, d, { enumerable: !0, configurable: !0, writable: !0, value: t }) : m[d] = t, c = (m, d) => {
6
+ for (var t in d || (d = {}))
7
+ K.call(d, t) && T(m, t, d[t]);
8
+ if (S)
9
+ for (var t of S(d))
10
+ Q.call(d, t) && T(m, t, d[t]);
11
+ return m;
12
+ }, _ = (m, d) => H(m, J(d));
13
13
  import { jsx as y } from "react/jsx-runtime";
14
- import { Empty as w } from "antd";
15
- import x from "./RegionItem.mjs";
16
- import { REGION_NAME_PREFIX as z } from "./constants.mjs";
17
- const U = ({
18
- labelDefinitions: r,
19
- labels: m,
14
+ import { Empty as R } from "antd";
15
+ import U from "./RegionItem.mjs";
16
+ import { REGION_NAME_PREFIX as W } from "./constants.mjs";
17
+ const V = ({
18
+ labelDefinitions: m,
19
+ labels: d,
20
20
  selectedRegion: t,
21
21
  activeLabelValue: A,
22
- activeRegionNumber: M,
23
- onChange: d,
24
- onInputActive: P,
25
- onBlur: _,
26
- readOnly: O
27
- }) => !m || m.length === 0 ? /* @__PURE__ */ y("div", {
22
+ activeRegionNumber: X,
23
+ onChange: u,
24
+ onInputActive: $,
25
+ onBlur: j,
26
+ onDelete: f,
27
+ onRegionClick: k,
28
+ onOCR: q,
29
+ ocrRecognizing: F,
30
+ ocrErrors: I,
31
+ readOnly: w
32
+ }) => !d || d.length === 0 ? /* @__PURE__ */ y("div", {
28
33
  className: "vlm-text-panel",
29
34
  children: /* @__PURE__ */ y("div", {
30
35
  className: "vlm-text-panel-empty",
31
- children: /* @__PURE__ */ y(w, {
36
+ children: /* @__PURE__ */ y(R, {
32
37
  description: "暂无标注数据,按R键开始标注吧"
33
38
  })
34
39
  })
35
40
  }) : /* @__PURE__ */ y("div", {
36
41
  className: "vlm-text-panel",
37
- children: m.map((u, v) => {
38
- const $ = A != null && M === v && A.region.id === u.id, R = $ ? A.label.id : void 0;
39
- return /* @__PURE__ */ y(x, {
40
- name: `${z}${v + 1}`,
41
- labelDefinitions: r != null ? r : [],
42
- region: u,
43
- isSelected: (t == null ? void 0 : t.id) === u.id,
44
- isActive: $,
45
- activeLabelId: R,
46
- readOnly: O,
47
- onFocus: (N) => {
48
- const c = r == null ? void 0 : r.find((F) => F.id === N);
49
- if (!c)
42
+ children: d.map((p, N) => {
43
+ var G, M;
44
+ const E = A != null && X === N && A.region.id === p.id, x = E ? A.label.id : void 0;
45
+ return /* @__PURE__ */ y(U, {
46
+ name: `${W}${N + 1}`,
47
+ labelDefinitions: m != null ? m : [],
48
+ region: p,
49
+ isSelected: (t == null ? void 0 : t.id) === p.id,
50
+ isActive: E,
51
+ activeLabelId: x,
52
+ readOnly: w,
53
+ onDelete: f,
54
+ onRegionClick: k,
55
+ onOCR: q,
56
+ isOCRRecognizing: (G = F == null ? void 0 : F.has(p.id)) != null ? G : !1,
57
+ hasOCRError: (M = I == null ? void 0 : I.has(p.id)) != null ? M : !1,
58
+ onFocus: (O) => {
59
+ const r = m == null ? void 0 : m.find((P) => P.id === O);
60
+ if (!r)
50
61
  return;
51
- const p = m == null ? void 0 : m[v];
52
- p && (P ? P({
53
- label: c,
54
- region: E({}, p)
55
- }, v) : d == null || d({
56
- label: c,
57
- region: p
58
- }, v));
62
+ const v = d == null ? void 0 : d[N];
63
+ v && ($ ? $({
64
+ label: r,
65
+ region: c({}, v)
66
+ }, N) : u == null || u({
67
+ label: r,
68
+ region: v
69
+ }, N));
59
70
  },
60
- onBlur: (N) => {
61
- const c = r == null ? void 0 : r.find((p) => p.id === N);
62
- c && (c && _ ? _({
63
- label: c,
64
- region: E({}, u)
65
- }, v) : d == null || d(null));
71
+ onBlur: (O) => {
72
+ const r = m == null ? void 0 : m.find((v) => v.id === O);
73
+ r && (r && j ? j({
74
+ label: r,
75
+ region: c({}, p)
76
+ }, N) : u == null || u(null));
66
77
  },
67
- onChange: (N, c) => {
68
- const p = r == null ? void 0 : r.find((F) => F.id === N);
69
- p && d && d({
70
- label: p,
71
- region: I(E({}, u), {
72
- content: I(E({}, u.content), {
73
- [N]: c
78
+ onChange: (O, r) => {
79
+ const v = m == null ? void 0 : m.find((P) => P.id === O);
80
+ v && u && u({
81
+ label: v,
82
+ region: _(c({}, p), {
83
+ content: _(c({}, p.content), {
84
+ [O]: r
74
85
  })
75
86
  })
76
- }, v);
87
+ }, N);
77
88
  }
78
- }, u.id);
89
+ }, p.id);
79
90
  })
80
91
  });
81
92
  export {
82
- U as default
93
+ V as default
83
94
  };
@@ -1,47 +1,62 @@
1
- import { useRef as t, useCallback as A } from "react";
2
- import { Modal as L } from "antd";
3
- import { DELETE_MODAL_TITLE as O, DELETE_MODAL_CONTENT as c, DELETE_MODAL_OK_TEXT as k, DELETE_MODAL_CANCEL_TEXT as C } from "../../constants.mjs";
4
- const v = ({
5
- canvas: r,
6
- onRegionChange: u,
7
- updateRegionNames: T,
1
+ import { useRef as X, useCallback as A } from "react";
2
+ import { Modal as K } from "antd";
3
+ import { DELETE_MODAL_TITLE as q, DELETE_MODAL_CONTENT as z, DELETE_MODAL_OK_TEXT as B, DELETE_MODAL_CANCEL_TEXT as F } from "../../constants.mjs";
4
+ const O = ({
5
+ canvas: l,
6
+ onRegionChange: o,
7
+ updateRegionNames: _,
8
8
  rectMapRef: f,
9
- textLayersMapRef: n,
10
- textLayoutContentMapRef: D,
11
- regionNameTextMapRef: E,
12
- ocrLoadingIconMapRef: m
9
+ textLayersMapRef: e,
10
+ textLayoutContentMapRef: s,
11
+ regionNameTextMapRef: m,
12
+ ocrLoadingIconMapRef: d
13
13
  }) => {
14
- const o = t(!1);
14
+ const E = X(!1), k = A((r) => {
15
+ if (!l || E.current)
16
+ return;
17
+ const D = f.current.get(r);
18
+ D && (E.current = !0, K.confirm({
19
+ title: q,
20
+ content: z,
21
+ okText: B,
22
+ cancelText: F,
23
+ onOk: () => {
24
+ const i = e.current.get(r);
25
+ i && (i.forEach((u) => {
26
+ u.off("mousedown"), u.off("mouseover"), u.off("mouseout"), s.current.delete(u), l.remove(u);
27
+ }), e.current.delete(r));
28
+ const T = m.current.get(r);
29
+ T && (r.off("moved"), r.off("modified"), l.remove(T), m.current.delete(r));
30
+ const n = d.current.get(r);
31
+ n && (l.remove(n), d.current.delete(r)), l.remove(r), f.current.delete(r), _(), o && o(D, "delete"), l.renderAll(), E.current = !1;
32
+ },
33
+ onCancel: () => {
34
+ E.current = !1;
35
+ },
36
+ afterClose: () => {
37
+ E.current = !1;
38
+ }
39
+ }));
40
+ }, [l, o, _, f, e, s, m, d]), w = A((r) => {
41
+ if (!l)
42
+ return;
43
+ const D = f.current.get(r);
44
+ if (!D)
45
+ return;
46
+ const i = e.current.get(r);
47
+ i && (i.forEach((u) => {
48
+ u.off("mousedown"), u.off("mouseover"), u.off("mouseout"), s.current.delete(u), l.remove(u);
49
+ }), e.current.delete(r));
50
+ const T = m.current.get(r);
51
+ T && (r.off("moved"), r.off("modified"), l.remove(T), m.current.delete(r));
52
+ const n = d.current.get(r);
53
+ n && (l.remove(n), d.current.delete(r)), l.remove(r), f.current.delete(r), _(), o && o(D, "delete"), l.renderAll();
54
+ }, [l, o, _, f, e, s, m, d]);
15
55
  return {
16
- performDelete: A((e) => {
17
- if (!r || o.current)
18
- return;
19
- const d = f.current.get(e);
20
- d && (o.current = !0, L.confirm({
21
- title: O,
22
- content: c,
23
- okText: k,
24
- cancelText: C,
25
- onOk: () => {
26
- const i = n.current.get(e);
27
- i && (i.forEach((l) => {
28
- l.off("mousedown"), l.off("mouseover"), l.off("mouseout"), D.current.delete(l), r.remove(l);
29
- }), n.current.delete(e));
30
- const s = E.current.get(e);
31
- s && (e.off("moved"), e.off("modified"), r.remove(s), E.current.delete(e));
32
- const _ = m.current.get(e);
33
- _ && (r.remove(_), m.current.delete(e)), r.remove(e), f.current.delete(e), T(), u && u(d, "delete"), r.renderAll(), o.current = !1;
34
- },
35
- onCancel: () => {
36
- o.current = !1;
37
- },
38
- afterClose: () => {
39
- o.current = !1;
40
- }
41
- }));
42
- }, [r, u, T, f, n, D, E, m])
56
+ performDelete: k,
57
+ deleteDirectly: w
43
58
  };
44
59
  };
45
60
  export {
46
- v as useDeleteRegion
61
+ O as useDeleteRegion
47
62
  };