@emailmaker/filemanager 1.1.69 → 1.1.71

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.
@@ -1,5 +1,5 @@
1
- import { B as e, D as t, G as n, K as r, N as i, P as a, R as o, U as s, _ as c, g as l, t as u, v as d, y as f } from "./file-manager-hooks-aNT0w8kI.js";
2
- import { i as p, n as m, o as h, r as g, s as _, t as ee } from "./file-manager-useMediaListEngine-zkDk3m1H.js";
1
+ import { B as e, F as t, G as n, H as r, I as i, J as a, b as o, k as s, q as c, t as l, v as u, x as d, y as f } from "./file-manager-hooks-vqT-4jeg.js";
2
+ import { i as p, n as m, o as h, r as g, s as _, t as ee } from "./file-manager-useMediaListEngine-BitrHuUM.js";
3
3
  import v from "react";
4
4
  import { Button as y, Checkbox as b, ColorPicker as x, Divider as te, Form as S, Input as C, InputNumber as w, Modal as ne, Space as T, Spin as E, Typography as re } from "antd";
5
5
  import { Fragment as ie, jsx as D, jsxs as O } from "react/jsx-runtime";
@@ -64,30 +64,30 @@ var A = {
64
64
  iconsHeaderDivider: "iconsHeaderDivider",
65
65
  copyToFolderModalBody: "copyToFolderModalBody",
66
66
  copyToFolderModalLoadingOverlay: "copyToFolderModalLoadingOverlay"
67
- }, le = ({ query: e, onQueryChange: t, onSubmit: n, hasResults: r = !1, inputRef: i }) => {
68
- let { t: a } = s(), { options: c } = o(), { config: l } = c, u = e.length > 0 && r;
67
+ }, le = ({ query: t, onQueryChange: r, onSubmit: i, hasResults: a = !1, inputRef: o }) => {
68
+ let { t: s } = n(), { options: c } = e(), { config: l } = c, u = t.length > 0 && a;
69
69
  return /* @__PURE__ */ O("div", {
70
70
  className: A.iconsSearchFormCenteredContainer,
71
71
  children: [/* @__PURE__ */ D(S, {
72
72
  layout: "inline",
73
- onFinish: n,
73
+ onFinish: i,
74
74
  className: u ? A.iconsSearchResults : A.iconsSearchFormCentered,
75
75
  children: /* @__PURE__ */ D(S.Item, {
76
76
  className: A.iconsSearchFormInput,
77
77
  children: /* @__PURE__ */ D(C, {
78
- ref: i,
78
+ ref: o,
79
79
  className: A.iconsSearchFormInputInput,
80
80
  allowClear: !0,
81
81
  prefix: /* @__PURE__ */ D(ce, {
82
82
  size: 16,
83
83
  strokeWidth: l?.iconStrokeWidth,
84
- onClick: n
84
+ onClick: i
85
85
  }),
86
- placeholder: a("Search icons"),
87
- value: e,
88
- onChange: (e) => t(e.target.value),
89
- onKeyDown: (e) => e.code === "Space" && n(),
90
- onPressEnter: n,
86
+ placeholder: s("Search icons"),
87
+ value: t,
88
+ onChange: (e) => r(e.target.value),
89
+ onKeyDown: (e) => e.code === "Space" && i(),
90
+ onPressEnter: i,
91
91
  spellCheck: "false"
92
92
  })
93
93
  })
@@ -97,7 +97,7 @@ var A = {
97
97
  })]
98
98
  });
99
99
  }, ue = (e) => {
100
- let { t } = s(), { colorHex: n, setColorHex: r, colorHex2: i, setColorHex2: a, colorHex3: o, setColorHex3: c, sizePx: l, setSizePx: u, strokeWidth: d, setStrokeWidth: f, showSecondColor: p, showThirdColor: m } = e;
100
+ let { t } = n(), { colorHex: r, setColorHex: i, colorHex2: a, setColorHex2: o, colorHex3: s, setColorHex3: c, sizePx: l, setSizePx: u, strokeWidth: d, setStrokeWidth: f, showSecondColor: p, showThirdColor: m } = e;
101
101
  return /* @__PURE__ */ D("div", {
102
102
  className: A.iconsControls,
103
103
  children: /* @__PURE__ */ O("div", {
@@ -149,13 +149,13 @@ var A = {
149
149
  /* @__PURE__ */ O("div", {
150
150
  className: A.iconsControlElement,
151
151
  children: [/* @__PURE__ */ D("span", { children: t("Color1") }), /* @__PURE__ */ D(x, {
152
- value: n,
152
+ value: r,
153
153
  format: "hex",
154
154
  disabledAlpha: !0,
155
155
  showText: !0,
156
156
  onChange: (e, t) => {
157
157
  let n = typeof e == "string" ? e : e?.toHexString ? e.toHexString() : t;
158
- r(n);
158
+ i(n);
159
159
  },
160
160
  size: "middle"
161
161
  })]
@@ -163,13 +163,13 @@ var A = {
163
163
  p && /* @__PURE__ */ O("div", {
164
164
  className: A.iconsControlElement,
165
165
  children: [/* @__PURE__ */ D("span", { children: t("Color2") }), /* @__PURE__ */ D(x, {
166
- value: i,
166
+ value: a,
167
167
  format: "hex",
168
168
  disabledAlpha: !0,
169
169
  showText: !0,
170
170
  onChange: (e, t) => {
171
171
  let n = typeof e == "string" ? e : e?.toHexString ? e.toHexString() : t;
172
- a(n);
172
+ o(n);
173
173
  },
174
174
  size: "middle"
175
175
  })]
@@ -177,7 +177,7 @@ var A = {
177
177
  m && /* @__PURE__ */ O("div", {
178
178
  className: A.iconsControlElement,
179
179
  children: [/* @__PURE__ */ D("span", { children: t("Color3") }), /* @__PURE__ */ D(x, {
180
- value: o,
180
+ value: s,
181
181
  format: "hex",
182
182
  disabledAlpha: !0,
183
183
  showText: !0,
@@ -196,8 +196,8 @@ var A = {
196
196
  }, j = /* @__PURE__ */ D(k, {
197
197
  style: { fontSize: 20 },
198
198
  spin: !0
199
- }), de = 240, fe = 160, M = 56, pe = ({ items: e, loading: t, isCollectingResults: n = !1, hasMore: r = !1, hasQuery: i, selectedHash: a, onItemClick: o, onInsert: c, onLoadMore: l, colorVars: d, svgTextMap: f, previewSize: p, selectedHashes: m, onToggleSelect: g }) => {
200
- let { t: y } = s(), { ThumbsUpIcon: x } = _(), te = !!(m && m.size > 0), S = v.useRef(null), { positionedItems: C, containerHeight: w, isNearEnd: ne, handleViewportChange: T } = ee({
199
+ }), de = 240, fe = 160, M = 56, pe = ({ items: e, loading: t, isCollectingResults: r = !1, hasMore: i = !1, hasQuery: a, selectedHash: o, onItemClick: s, onInsert: c, onLoadMore: u, colorVars: d, svgTextMap: f, previewSize: p, selectedHashes: m, onToggleSelect: g }) => {
200
+ let { t: y } = n(), { ThumbsUpIcon: x } = _(), te = !!(m && m.size > 0), S = v.useRef(null), { positionedItems: C, containerHeight: w, isNearEnd: ne, handleViewportChange: T } = ee({
201
201
  items: e,
202
202
  getId: (e) => e.hash,
203
203
  getPreviewSrc: () => void 0,
@@ -207,23 +207,23 @@ var A = {
207
207
  estimatedItemHeight: (p ?? 50) + M,
208
208
  gap: 16,
209
209
  prefetchThresholdPx: de
210
- }), re = u(T, [e.length, p ?? 50]);
210
+ }), re = l(T, [e.length, p ?? 50]);
211
211
  v.useEffect(() => {
212
- r || (S.current = null);
213
- }, [r, e.length]), v.useEffect(() => {
214
- if (!t && !n && r && e.length > 0 && ne) {
212
+ i || (S.current = null);
213
+ }, [i, e.length]), v.useEffect(() => {
214
+ if (!t && !r && i && e.length > 0 && ne) {
215
215
  if (S.current === e.length) return;
216
- S.current = e.length, l?.();
216
+ S.current = e.length, u?.();
217
217
  }
218
218
  }, [
219
+ i,
219
220
  r,
220
- n,
221
221
  ne,
222
222
  e.length,
223
223
  t,
224
- l
224
+ u
225
225
  ]);
226
- let k = i ? /* @__PURE__ */ D("div", {
226
+ let k = a ? /* @__PURE__ */ D("div", {
227
227
  className: A.iconsGridEmptyState,
228
228
  children: /* @__PURE__ */ D(h, {})
229
229
  }) : /* @__PURE__ */ D("div", {
@@ -261,7 +261,7 @@ var A = {
261
261
  className: A.iconsGridVirtualCanvas,
262
262
  style: { height: w },
263
263
  children: C.map(({ row: e, layout: t }) => {
264
- let n = e.item, r = !!(m && m.has(n.hash) || a === n.hash), i = f[n.hash];
264
+ let n = e.item, r = !!(m && m.has(n.hash) || o === n.hash), i = f[n.hash];
265
265
  return /* @__PURE__ */ O("div", {
266
266
  style: {
267
267
  position: "absolute",
@@ -271,7 +271,7 @@ var A = {
271
271
  height: t.height
272
272
  },
273
273
  className: `${A.iconsGridItem} ${r ? A.iconsGridItemSelected : ""} ${te ? A.iconsGridShowCheckboxes : ""}`,
274
- onClick: () => o(n),
274
+ onClick: () => s(n),
275
275
  children: [
276
276
  /* @__PURE__ */ D("div", {
277
277
  style: { height: p ?? 50 },
@@ -324,7 +324,7 @@ var A = {
324
324
  ]
325
325
  }, n.hash);
326
326
  })
327
- }), n && /* @__PURE__ */ D("div", {
327
+ }), r && /* @__PURE__ */ D("div", {
328
328
  className: A.iconsGridLoadingMore,
329
329
  children: /* @__PURE__ */ D(E, { indicator: j })
330
330
  })] }), t && e.length === 0 && /* @__PURE__ */ D("div", {
@@ -1762,12 +1762,12 @@ function it(e) {
1762
1762
  ].filter(Boolean).join("|"), c = et.get(s);
1763
1763
  if (c) return c;
1764
1764
  if (n?.signal?.aborted) throw new DOMException("Aborted", "AbortError");
1765
- let u = rt(i, a, o), d = u;
1766
- e ? d = $e(d, { strokeWidth: n?.strokeWidth }) : n?.inlineColors && (d = l(d, n.inlineColors));
1765
+ let l = rt(i, a, o), d = l;
1766
+ e ? d = $e(d, { strokeWidth: n?.strokeWidth }) : n?.inlineColors && (d = u(d, n.inlineColors));
1767
1767
  let f = `data:image/svg+xml;utf8,${encodeURIComponent(d)}`, p = {
1768
1768
  text: d,
1769
1769
  url: f,
1770
- original: u
1770
+ original: l
1771
1771
  };
1772
1772
  return et.set(s, p), p;
1773
1773
  }, [e]),
@@ -1776,29 +1776,29 @@ function it(e) {
1776
1776
  }
1777
1777
  //#endregion
1778
1778
  //#region packages/file-manager/src/components/ImageIcons/useIconsCopyToFolder.tsx
1779
- async function at(t) {
1780
- let { hashes: i, items: a, folderId: o, dataProviders: s, getPngDataUrlForItem: c, dataUrlToBlob: l, config: u } = t, d = 0, f = 0;
1781
- for (let t of i) {
1782
- let i = a.find((e) => e.hash === t);
1783
- if (!i) {
1779
+ async function at(e) {
1780
+ let { hashes: t, items: n, folderId: i, dataProviders: o, getPngDataUrlForItem: s, dataUrlToBlob: l, config: u } = e, d = 0, f = 0;
1781
+ for (let e of t) {
1782
+ let t = n.find((t) => t.hash === e);
1783
+ if (!t) {
1784
1784
  f += 1;
1785
1785
  continue;
1786
1786
  }
1787
- let p = await c(i);
1787
+ let p = await s(t);
1788
1788
  if (!p) {
1789
1789
  f += 1;
1790
1790
  continue;
1791
1791
  }
1792
- let m = await e(s, r(`${i.name?.trim() || `icon-${t}`}.png`, u), o, !1, n(u)), h = l(p, "image/png"), g = new File([h], m, {
1792
+ let m = await r(o, a(`${t.name?.trim() || `icon-${e}`}.png`, u), i, !1, c(u)), h = l(p, "image/png"), g = new File([h], m, {
1793
1793
  type: "image/png",
1794
1794
  lastModified: Date.now()
1795
1795
  });
1796
1796
  try {
1797
- await s.uploadFile({
1797
+ await o.uploadFile({
1798
1798
  name: m,
1799
1799
  size: g.size,
1800
1800
  type: g.type,
1801
- folderId: o,
1801
+ folderId: i,
1802
1802
  data: g,
1803
1803
  extension: "png"
1804
1804
  }), d += 1;
@@ -1811,8 +1811,8 @@ async function at(t) {
1811
1811
  failCount: f
1812
1812
  };
1813
1813
  }
1814
- var ot = ({ items: e, selectedHashes: n, getPngDataUrlForItem: r, dataUrlToBlob: i, clearSelection: c }) => {
1815
- let { t: l } = s(), { options: u, state: d } = o(), f = a(), [p, h] = v.useState(!1), [g] = S.useForm(), [ee, y] = v.useState(!1), b = v.useRef(!1), { state: x, actions: { fetchFolders: te, fetchChildFolders: C, handleModalOk: w } } = t(), { EmptyFolderIcon: ne } = _(), { activeFormField: T, setActiveFormField: E, generateMenuItemsFromFolders: re } = m({
1814
+ var ot = ({ items: t, selectedHashes: r, getPngDataUrlForItem: a, dataUrlToBlob: o, clearSelection: c }) => {
1815
+ let { t: l } = n(), { options: u, state: d } = e(), f = i(), [p, h] = v.useState(!1), [g] = S.useForm(), [ee, y] = v.useState(!1), b = v.useRef(!1), { state: x, actions: { fetchFolders: te, fetchChildFolders: C, handleModalOk: w } } = s(), { EmptyFolderIcon: ne } = _(), { activeFormField: T, setActiveFormField: E, generateMenuItemsFromFolders: re } = m({
1816
1816
  folders: Array.isArray(x.folders) ? x.folders : [],
1817
1817
  selectedFolder: d.selectedFolder,
1818
1818
  EmptyFolderIcon: ne,
@@ -1827,10 +1827,10 @@ var ot = ({ items: e, selectedHashes: n, getPngDataUrlForItem: r, dataUrlToBlob:
1827
1827
  T,
1828
1828
  g,
1829
1829
  E
1830
- ]), O = v.useCallback(async (t) => {
1830
+ ]), O = v.useCallback(async (e) => {
1831
1831
  try {
1832
- let { dataProviders: a } = u;
1833
- if (!a || !a.uploadFile && !a.uploadFiles) {
1832
+ let { dataProviders: n } = u;
1833
+ if (!n || !n.uploadFile && !n.uploadFiles) {
1834
1834
  f.error({
1835
1835
  id: "FILES_UPLOAD_PROVIDER_NOT_CONFIGURED",
1836
1836
  message: l("API-endpoint for file upload is not configured"),
@@ -1838,16 +1838,16 @@ var ot = ({ items: e, selectedHashes: n, getPngDataUrlForItem: r, dataUrlToBlob:
1838
1838
  });
1839
1839
  return;
1840
1840
  }
1841
- let o = t || d?.selectedFolder || void 0, s = Array.from(n);
1841
+ let i = e || d?.selectedFolder || void 0, s = Array.from(r);
1842
1842
  if (s.length === 0) return;
1843
1843
  let { successCount: p, failCount: m } = await at({
1844
1844
  hashes: s,
1845
- items: e,
1846
- folderId: o,
1845
+ items: t,
1846
+ folderId: i,
1847
1847
  dataProviders: {
1848
- uploadFile: a.uploadFile ?? (async (e) => {
1849
- if (!a.uploadFiles) throw Error("Upload is not supported by data provider");
1850
- let t = await a.uploadFiles({
1848
+ uploadFile: n.uploadFile ?? (async (e) => {
1849
+ if (!n.uploadFiles) throw Error("Upload is not supported by data provider");
1850
+ let t = await n.uploadFiles({
1851
1851
  folderId: e.folderId,
1852
1852
  items: [{
1853
1853
  name: e.name,
@@ -1857,18 +1857,18 @@ var ot = ({ items: e, selectedHashes: n, getPngDataUrlForItem: r, dataUrlToBlob:
1857
1857
  data: e.data,
1858
1858
  extension: e.extension
1859
1859
  }]
1860
- }), n = t?.detailed?.[0];
1861
- if (!t || !t.success || !n || n.success === !1) {
1862
- let e = n?.error?.message || t?.error?.message || "Upload failed";
1860
+ }), r = t?.detailed?.[0];
1861
+ if (!t || !t.success || !r || r.success === !1) {
1862
+ let e = r?.error?.message || t?.error?.message || "Upload failed";
1863
1863
  throw Error(e);
1864
1864
  }
1865
- return n.data;
1865
+ return r.data;
1866
1866
  }),
1867
- getFiles: a.getFiles,
1868
- getFolders: a.getFolders
1867
+ getFiles: n.getFiles,
1868
+ getFolders: n.getFolders
1869
1869
  },
1870
- getPngDataUrlForItem: r,
1871
- dataUrlToBlob: i,
1870
+ getPngDataUrlForItem: a,
1871
+ dataUrlToBlob: o,
1872
1872
  config: u?.config
1873
1873
  });
1874
1874
  p > 0 && f.success({
@@ -1879,7 +1879,7 @@ var ot = ({ items: e, selectedHashes: n, getPngDataUrlForItem: r, dataUrlToBlob:
1879
1879
  successCount: p,
1880
1880
  totalCount: s.length,
1881
1881
  itemIds: s,
1882
- folderId: o ?? null
1882
+ folderId: i ?? null
1883
1883
  }
1884
1884
  }), m > 0 && f.error({
1885
1885
  id: "FILES_COPY_ERROR",
@@ -1889,7 +1889,7 @@ var ot = ({ items: e, selectedHashes: n, getPngDataUrlForItem: r, dataUrlToBlob:
1889
1889
  failCount: m,
1890
1890
  totalCount: s.length,
1891
1891
  itemIds: s,
1892
- folderId: o ?? null
1892
+ folderId: i ?? null
1893
1893
  }
1894
1894
  }), c();
1895
1895
  } catch (e) {
@@ -1899,21 +1899,21 @@ var ot = ({ items: e, selectedHashes: n, getPngDataUrlForItem: r, dataUrlToBlob:
1899
1899
  placement: "bottomRight",
1900
1900
  innerException: e,
1901
1901
  data: {
1902
- failCount: Array.from(n).length || 0,
1903
- totalCount: Array.from(n).length || 0,
1904
- itemIds: Array.from(n),
1902
+ failCount: Array.from(r).length || 0,
1903
+ totalCount: Array.from(r).length || 0,
1904
+ itemIds: Array.from(r),
1905
1905
  folderId: d?.selectedFolder ?? null
1906
1906
  }
1907
1907
  });
1908
1908
  }
1909
1909
  }, [
1910
1910
  c,
1911
- i,
1912
- r,
1913
- e,
1911
+ o,
1912
+ a,
1913
+ t,
1914
1914
  f,
1915
1915
  u,
1916
- n,
1916
+ r,
1917
1917
  d?.selectedFolder,
1918
1918
  l
1919
1919
  ]);
@@ -1966,8 +1966,8 @@ async function ut(e, t, n) {
1966
1966
  };
1967
1967
  return await Promise.all(Array.from({ length: a }, () => o())), r;
1968
1968
  }
1969
- var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
1970
- let { t: a } = s(), u = i(), [m, h] = v.useState(""), _ = t === void 0 ? m : t, ee = n === void 0 ? h : n, [b, x] = v.useState(""), [w, k] = v.useState([]), [ce, j] = v.useState(0), [de, fe] = v.useState(!1), [M, me] = v.useState(!1), [he, N] = v.useState(!1), [P, _e] = v.useState(null), [F, I] = v.useState({}), [L, ve] = v.useState({}), [R, ye] = v.useState("#000000"), [z, be] = v.useState("#ff007a"), [B, xe] = v.useState("#00C2FF"), [V, Se] = v.useState(1), [H, Ce] = v.useState(50), [we, Te] = v.useState(!1), { options: U } = o(), W = v.useRef(!1), G = v.useRef(null), Ee = v.useRef(0), De = v.useRef(null), Oe = v.useRef(null), K = v.useRef(void 0);
1969
+ var dt = ({ customRequest: r, query: i, setQuery: a, inputRef: s }) => {
1970
+ let { t: c } = n(), l = t(), [m, h] = v.useState(""), _ = i === void 0 ? m : i, ee = a === void 0 ? h : a, [b, x] = v.useState(""), [w, k] = v.useState([]), [ce, j] = v.useState(0), [de, fe] = v.useState(!1), [M, me] = v.useState(!1), [he, N] = v.useState(!1), [P, _e] = v.useState(null), [F, I] = v.useState({}), [L, ve] = v.useState({}), [R, ye] = v.useState("#000000"), [z, be] = v.useState("#ff007a"), [B, xe] = v.useState("#00C2FF"), [V, Se] = v.useState(1), [H, Ce] = v.useState(50), [we, Te] = v.useState(!1), { options: U } = e(), W = v.useRef(!1), G = v.useRef(null), Ee = v.useRef(0), De = v.useRef(null), Oe = v.useRef(null), K = v.useRef(void 0);
1971
1971
  K.current = ge(U?.config);
1972
1972
  let ke = v.useRef(U?.config?.locale);
1973
1973
  ke.current = U?.config?.locale;
@@ -1980,13 +1980,13 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
1980
1980
  L,
1981
1981
  F
1982
1982
  ]), ze = !!J?.hasGradient, Y = v.useMemo(() => {
1983
- let e = f("icon-color-2", "i");
1983
+ let e = d("icon-color-2", "i");
1984
1984
  return w.some((t) => {
1985
1985
  let n = F[t.hash];
1986
1986
  return !!n && e.test(n);
1987
1987
  });
1988
1988
  }, [w, F]), X = v.useMemo(() => {
1989
- let e = f("icon-color-3", "i");
1989
+ let e = d("icon-color-3", "i");
1990
1990
  return w.some((t) => {
1991
1991
  let n = F[t.hash];
1992
1992
  return !!n && e.test(n);
@@ -2011,9 +2011,9 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2011
2011
  let t = e.override?.query ?? b;
2012
2012
  if (!t || t.trim().length < 3 || (e.initial ? M : he || M) || !W.current) return;
2013
2013
  e.initial ? (Fe.current = e.override?.stockIds === void 0 ? Be(t) : e.override.stockIds, me(!0), k([]), I({}), ve({}), j(0), fe(!1)) : N(!0);
2014
- let n = Fe.current, r = e.initial ? 0 : ce, i = e.initial ? st : ct, o = `${t}|${r}|${i}|${e.initial ? "i" : "m"}`;
2015
- if (!Ne.current.has(o)) {
2016
- Ne.current.add(o);
2014
+ let n = Fe.current, r = e.initial ? 0 : ce, i = e.initial ? st : ct, a = `${t}|${r}|${i}|${e.initial ? "i" : "m"}`;
2015
+ if (!Ne.current.has(a)) {
2016
+ Ne.current.add(a);
2017
2017
  try {
2018
2018
  let t = n.slice(r, r + i).map(He);
2019
2019
  if (!W.current) return;
@@ -2027,9 +2027,9 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2027
2027
  fe(r + t.length < n.length), j(r + t.length);
2028
2028
  } catch (e) {
2029
2029
  if (e?.name === "AbortError") return;
2030
- console.error(e), u.error(a("Request error"));
2030
+ console.error(e), l.error(c("Request error"));
2031
2031
  } finally {
2032
- W.current && (e.initial ? me(!1) : N(!1)), Ne.current.delete(o);
2032
+ W.current && (e.initial ? me(!1) : N(!1)), Ne.current.delete(a);
2033
2033
  }
2034
2034
  }
2035
2035
  }, [
@@ -2037,7 +2037,7 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2037
2037
  he,
2038
2038
  M,
2039
2039
  ce,
2040
- a
2040
+ c
2041
2041
  ]);
2042
2042
  v.useEffect(() => {
2043
2043
  Oe.current = Ke;
@@ -2167,7 +2167,7 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2167
2167
  w,
2168
2168
  L
2169
2169
  ]);
2170
- let $e = v.useCallback((e) => l(e, {
2170
+ let $e = v.useCallback((e) => u(e, {
2171
2171
  colorHex: R,
2172
2172
  colorHex2: z,
2173
2173
  colorHex3: B
@@ -2212,8 +2212,8 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2212
2212
  signal: t,
2213
2213
  inlineColors: void 0
2214
2214
  })).text;
2215
- let r = $e(n), i = c(r, H);
2216
- return d(r, i.width, i.height);
2215
+ let r = $e(n), i = f(r, H);
2216
+ return o(r, i.width, i.height);
2217
2217
  } catch {
2218
2218
  return null;
2219
2219
  }
@@ -2228,24 +2228,24 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2228
2228
  V,
2229
2229
  F,
2230
2230
  !0
2231
- ]), dt = v.useCallback(async (t) => {
2231
+ ]), dt = v.useCallback(async (e) => {
2232
2232
  try {
2233
2233
  if (!W.current) return;
2234
2234
  Te(!0), Me.current?.abort();
2235
- let n = new AbortController();
2236
- Me.current = n;
2237
- let r = await at(t, n.signal);
2238
- if (!W.current || !r) return;
2239
- await Promise.resolve(e(r));
2235
+ let t = new AbortController();
2236
+ Me.current = t;
2237
+ let n = await at(e, t.signal);
2238
+ if (!W.current || !n) return;
2239
+ await Promise.resolve(r(n));
2240
2240
  } catch (e) {
2241
- console.error("IconsTab: insert error", e), u.error(a("Request error"));
2241
+ console.error("IconsTab: insert error", e), l.error(c("Request error"));
2242
2242
  } finally {
2243
2243
  W.current && Te(!1);
2244
2244
  }
2245
2245
  }, [
2246
- e,
2246
+ r,
2247
2247
  at,
2248
- a
2248
+ c
2249
2249
  ]), { isCopyIconsModalVisible: ft, isCopyLoading: $, copyForm: pt, openCopyModal: mt, closeCopyModal: ht, resetAfterClose: gt, handleCopyTreeSelect: _t, handleIconsCopyOk: vt, fetchChildFolders: yt, generateMenuItemsFromFolders: bt, handleCreateFolderAndCopy: xt } = ot({
2250
2250
  items: w,
2251
2251
  selectedHashes: q,
@@ -2265,24 +2265,24 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2265
2265
  children: [
2266
2266
  q.size,
2267
2267
  " ",
2268
- a("selected")
2268
+ c("selected")
2269
2269
  ]
2270
2270
  }), /* @__PURE__ */ D(y, {
2271
2271
  icon: /* @__PURE__ */ D(se, { size: 16 }),
2272
2272
  onClick: tt,
2273
- children: a("Deselected")
2273
+ children: c("Deselected")
2274
2274
  })]
2275
2275
  }), /* @__PURE__ */ D(T, { children: /* @__PURE__ */ D(y, {
2276
2276
  icon: /* @__PURE__ */ D(ae, { size: 16 }),
2277
2277
  onClick: mt,
2278
- children: a("Copy to folder")
2278
+ children: c("Copy to folder")
2279
2279
  }) })]
2280
2280
  }) : /* @__PURE__ */ D(le, {
2281
2281
  query: _,
2282
2282
  onQueryChange: ee,
2283
2283
  onSubmit: qe,
2284
2284
  hasResults: w.length > 0 || M,
2285
- inputRef: r
2285
+ inputRef: s
2286
2286
  }),
2287
2287
  St ? /* @__PURE__ */ D(ue, {
2288
2288
  colorHex: R,
@@ -2330,7 +2330,7 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2330
2330
  style: { height: 40 },
2331
2331
  loading: we,
2332
2332
  onClick: () => dt(nt),
2333
- children: a("Choose")
2333
+ children: c("Choose")
2334
2334
  }) })
2335
2335
  })]
2336
2336
  }) : null
@@ -2338,7 +2338,7 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2338
2338
  }), /* @__PURE__ */ D(ne, {
2339
2339
  title: /* @__PURE__ */ D("div", {
2340
2340
  className: "modal-title",
2341
- children: a("Copy to folder")
2341
+ children: c("Copy to folder")
2342
2342
  }),
2343
2343
  open: ft,
2344
2344
  onCancel: () => {
@@ -2358,7 +2358,7 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2358
2358
  children: [/* @__PURE__ */ D(oe, {
2359
2359
  size: 18,
2360
2360
  strokeWidth: U.config?.iconStrokeWidth
2361
- }), a("Create folder")]
2361
+ }), c("Create folder")]
2362
2362
  }), /* @__PURE__ */ D(y, {
2363
2363
  type: "primary",
2364
2364
  className: g.folderButton,
@@ -2366,7 +2366,7 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2366
2366
  ht();
2367
2367
  },
2368
2368
  loading: $,
2369
- children: a("Done")
2369
+ children: c("Done")
2370
2370
  })]
2371
2371
  }),
2372
2372
  afterClose: () => gt(),
@@ -2380,7 +2380,7 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2380
2380
  layout: "vertical",
2381
2381
  initialValues: {
2382
2382
  targetFolder: "folders",
2383
- folderName: a("New folder"),
2383
+ folderName: c("New folder"),
2384
2384
  is_force_create: !1
2385
2385
  },
2386
2386
  children: /* @__PURE__ */ O("div", {
@@ -2390,7 +2390,7 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2390
2390
  name: "targetFolder",
2391
2391
  rules: [{
2392
2392
  required: !0,
2393
- message: a("Select the destination folder")
2393
+ message: c("Select the destination folder")
2394
2394
  }],
2395
2395
  className: g.formItem,
2396
2396
  children: /* @__PURE__ */ D(p, {
@@ -2399,7 +2399,7 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2399
2399
  targetForm: pt,
2400
2400
  onTreeSelect: _t,
2401
2401
  onComplete: vt,
2402
- actionButtonText: a("Copy here")
2402
+ actionButtonText: c("Copy here")
2403
2403
  }),
2404
2404
  fetchChildFolders: yt,
2405
2405
  disabledFolders: [],
@@ -2413,7 +2413,7 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2413
2413
  style: { display: "none" },
2414
2414
  rules: [{
2415
2415
  required: !0,
2416
- validator: (e, t) => typeof t == "string" && t.trim().length === 0 ? Promise.reject(Error(a("Enter the name of the folder"))) : Promise.resolve()
2416
+ validator: (e, t) => typeof t == "string" && t.trim().length === 0 ? Promise.reject(Error(c("Enter the name of the folder"))) : Promise.resolve()
2417
2417
  }],
2418
2418
  children: /* @__PURE__ */ D(C, {})
2419
2419
  }),
@@ -2431,4 +2431,4 @@ var dt = ({ customRequest: e, query: t, setQuery: n, inputRef: r }) => {
2431
2431
  //#endregion
2432
2432
  export { dt as IconsTab, dt as default };
2433
2433
 
2434
- //# sourceMappingURL=file-manager-IconsTab-BPDaI1rw.js.map
2434
+ //# sourceMappingURL=file-manager-IconsTab-pUKiId5k.js.map