@abyss-project/commons-front-core 11.1.1 → 11.1.2

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/editors.js CHANGED
@@ -1,27 +1,27 @@
1
1
  import { jsx as o, jsxs as T, Fragment as Oe } from "react/jsx-runtime";
2
- import vn, { useRef as j, useEffect as X, useState as L, useCallback as _, useMemo as ut, forwardRef as Lo, useImperativeHandle as zo, useReducer as _o } from "react";
3
- import { M as $o, K as Wo, O as Bo, Q as Ho, R as Uo, S as Go, U as Ko, V as jo, W as Un, X as Xo, Y as H, Z as Xt, _ as Ce, $ as pe, a0 as yn, a1 as Vo, a2 as At, a3 as co, a4 as uo, a5 as Zt, a6 as We, a7 as qt, a8 as po, a9 as Je, aa as xn, ab as Yo, ac as kn, ad as Cn, ae as Gn, af as Zo, ag as Kn, ah as Gt, ai as qo, aj as Jo, ak as Qo, al as go, am as fo, an as er, ao as tr, ap as nr, aq as or, ar as rr, as as ar, at as ir, au as sr, av as dr, aw as lr, ax as cr, ay as ur, az as pr, aA as gr, aB as fr, aC as hr, aD as mr, aE as br, aF as wr, aG as jn, aH as vr, aI as Xn, aJ as yr, aK as xr } from "./sortable.esm-BYVnqZQ-.js";
2
+ import bn, { useRef as j, useEffect as X, useState as L, useCallback as _, useMemo as ut, forwardRef as Lo, useImperativeHandle as zo, useReducer as _o } from "react";
3
+ import { M as $o, K as Wo, O as Bo, Q as Ho, R as Uo, S as Go, U as Ko, V as jo, W as Hn, X as Xo, Y as H, Z as Xt, _ as Ce, $ as pe, a0 as wn, a1 as Vo, a2 as At, a3 as co, a4 as uo, a5 as Zt, a6 as We, a7 as qt, a8 as po, a9 as Je, aa as vn, ab as Yo, ac as yn, ad as xn, ae as Un, af as Zo, ag as Gn, ah as Gt, ai as qo, aj as Jo, ak as Qo, al as go, am as fo, an as er, ao as tr, ap as nr, aq as or, ar as rr, as as ar, at as ir, au as sr, av as dr, aw as lr, ax as cr, ay as ur, az as pr, aA as gr, aB as fr, aC as hr, aD as mr, aE as br, aF as wr, aG as Kn, aH as vr, aI as jn, aJ as yr, aK as xr } from "./sortable.esm-BYVnqZQ-.js";
4
4
  import { styled as b, useTheme as kr } from "@mui/material/styles";
5
5
  import { useIntl as J } from "react-intl";
6
- import { s as ft, d as Me, D as Ae, p as i, h as Q, M as Qe, a as et, R as In, F as Vt, C as St, b as Tt, c as Ot, S as Et, e as Cr, f as ho, T as Ir, g as Sr, t as Mt, i as Xe, j as nt, k as Pt, N as On, A as Tr, l as Qt, u as Pr, m as Ar, n as Er, o as Or } from "./Tabs-CZQ1JYlW.js";
6
+ import { s as ft, d as Me, D as Ae, p as i, h as Q, M as Qe, a as et, R as kn, F as Vt, C as St, b as Tt, c as Ot, S as Et, e as Cr, f as ho, T as Ir, g as Sr, t as Mt, i as Xe, j as nt, k as Pt, N as En, A as Tr, l as Qt, u as Pr, m as Ar, n as Er, o as Or } from "./Tabs-CZQ1JYlW.js";
7
7
  import V from "@mui/material/Button";
8
- import Mn from "@mui/material/Checkbox";
8
+ import On from "@mui/material/Checkbox";
9
9
  import Jt from "@mui/material/CircularProgress";
10
10
  import tt from "@mui/material/FormControlLabel";
11
11
  import Yt from "@mui/material/OutlinedInput";
12
- import Rn from "@mui/material/Switch";
12
+ import Mn from "@mui/material/Switch";
13
13
  import { f as _e } from "./AbyssCloud-IuD91X6C.js";
14
14
  import Mr from "@mui/icons-material/OpenInNew";
15
15
  import { AssetKind as Pe } from "@abyss-project/main";
16
16
  import Rr from "@mui/icons-material/SaveOutlined";
17
- import { l as Nn } from "./lazy-value-Co76vxsM.js";
17
+ import { l as Rn } from "./lazy-value-Co76vxsM.js";
18
18
  import Nr from "@mui/icons-material/FolderOpenRounded";
19
19
  import Dr from "@mui/icons-material/GroupsRounded";
20
20
  import Fr from "@mui/icons-material/PersonRounded";
21
21
  import Lr from "@mui/icons-material/PictureAsPdfOutlined";
22
22
  import zr from "@mui/icons-material/Redo";
23
23
  import _r from "@mui/icons-material/Undo";
24
- import Sn from "@mui/material/Divider";
24
+ import Cn from "@mui/material/Divider";
25
25
  import $r from "@mui/icons-material/BrandingWatermarkOutlined";
26
26
  import Wr from "@mui/icons-material/CloudOutlined";
27
27
  import Br from "@mui/icons-material/CloudUploadOutlined";
@@ -55,11 +55,11 @@ import ua from "@mui/material/FormLabel";
55
55
  import pa from "@mui/material/MenuItem";
56
56
  import ga from "@mui/material/Radio";
57
57
  import fa from "@mui/material/RadioGroup";
58
- import Vn from "@mui/material/TextField";
58
+ import Xn from "@mui/material/TextField";
59
59
  import ha from "@mui/icons-material/WarningAmberOutlined";
60
60
  import ma from "@mui/icons-material/KeyboardArrowDown";
61
61
  import an from "@mui/material/Box";
62
- import Dn from "@mui/material/IconButton";
62
+ import Nn from "@mui/material/IconButton";
63
63
  import ba from "@mui/material/InputBase";
64
64
  import wa from "@mui/icons-material/Close";
65
65
  import va from "@mui/icons-material/DeleteOutline";
@@ -71,7 +71,7 @@ import Ia from "@mui/icons-material/AddRounded";
71
71
  import Sa from "@mui/icons-material/FitScreenOutlined";
72
72
  import Ta from "@mui/icons-material/KeyboardArrowUpRounded";
73
73
  import Pa from "@mui/icons-material/KeyboardArrowDownRounded";
74
- const ve = (e) => `ds.editors.markdown.crepe.${e}`, Yn = (e) => `ds.editors.markdown.aria.${e}`, Aa = (e) => {
74
+ const ve = (e) => `ds.editors.markdown.crepe.${e}`, Vn = (e) => `ds.editors.markdown.aria.${e}`, Aa = (e) => {
75
75
  const t = (r) => ({
76
76
  label: e(ve(`slash-menu.items.${r}`))
77
77
  }), n = (r) => e(ve(`slash-menu.groups.${r}`));
@@ -145,11 +145,11 @@ const ve = (e) => `ds.editors.markdown.crepe.${e}`, Yn = (e) => `ds.editors.mark
145
145
  l === void 0 || l === "" || (s.setAttribute("aria-label", l), r && s.setAttribute("role", r));
146
146
  });
147
147
  }, Oa = (e, t, n) => {
148
- const r = (...s) => s.map((d) => t(Yn(d)));
148
+ const r = (...s) => s.map((d) => t(Vn(d)));
149
149
  we(
150
150
  e,
151
151
  ".milkdown-toolbar .toolbar-item",
152
- n.map((s) => Ea.has(s) ? t(Yn(s)) : "")
152
+ n.map((s) => Ea.has(s) ? t(Vn(s)) : "")
153
153
  ), we(
154
154
  e,
155
155
  ".milkdown-block-handle .operation-item",
@@ -244,7 +244,7 @@ const ve = (e) => `ds.editors.markdown.crepe.${e}`, Yn = (e) => `ds.editors.mark
244
244
  };
245
245
  }, Ra = `${Me.down(
246
246
  Ae.Tablet
247
- )}, (pointer: coarse)`, sn = 28, dn = 16, Zn = 8, Na = b("div", {
247
+ )}, (pointer: coarse)`, sn = 28, dn = 16, Yn = 8, Na = b("div", {
248
248
  shouldForwardProp: (e) => e !== "editable"
249
249
  })(({ theme: e, editable: t }) => {
250
250
  const { tokens: n, fonts: r, radii: s, space: d, densityValues: l } = e.design, p = i(l.touchTarget), v = i(d[10] + d[6]), g = i(d[10]), h = i((l.touchTarget - 24) / 2), c = "& .milkdown .milkdown-table-block", k = `${c} .handle.cell-handle[data-role='col-drag-handle']`, E = `${c} .handle.cell-handle[data-role='row-drag-handle']`, w = `${c} .line-handle[data-role='x-line-drag-handle'] .add-button`, P = `${c} .line-handle[data-role='y-line-drag-handle'] .add-button`, S = (m, y = [k, E, w, P]) => y.map((M) => `${M}${m}`).join(", ");
@@ -339,13 +339,13 @@ const ve = (e) => `ds.editors.markdown.crepe.${e}`, Yn = (e) => `ds.editors.mark
339
339
  [`${k} .button-group`]: {
340
340
  top: "auto",
341
341
  bottom: i(
342
- (l.touchTarget + dn) / 2 + Zn
342
+ (l.touchTarget + dn) / 2 + Yn
343
343
  )
344
344
  },
345
345
  [`${E} .button-group`]: {
346
346
  top: "auto",
347
347
  bottom: i(
348
- (l.touchTarget + sn) / 2 + Zn
348
+ (l.touchTarget + sn) / 2 + Yn
349
349
  )
350
350
  },
351
351
  // A hidden handle stays where it was last shown, at opacity 0: its larger hit area must not
@@ -368,7 +368,7 @@ const ve = (e) => `ds.editors.markdown.crepe.${e}`, Yn = (e) => `ds.editors.mark
368
368
  documentRef: g,
369
369
  ...h
370
370
  }) => {
371
- const [c, k] = vn.useState(null), E = vn.useRef(void 0), { get: w } = Wo((P) => {
371
+ const [c, k] = bn.useState(null), E = bn.useRef(void 0), { get: w } = Wo((P) => {
372
372
  const S = Aa(p), m = s && r ? {
373
373
  "image-block": {
374
374
  ...S["image-block"],
@@ -445,7 +445,7 @@ const ve = (e) => `ds.editors.markdown.crepe.${e}`, Yn = (e) => `ds.editors.mark
445
445
  }, [n, w]), X(() => {
446
446
  e && c !== null && e(c);
447
447
  }, [c, e]), /* @__PURE__ */ o(Go, {});
448
- }, yl = (e) => {
448
+ }, xl = (e) => {
449
449
  const t = J(), n = j(null), r = j([]), s = j(void 0), d = (l) => t.formatMessage({ id: l });
450
450
  return X(() => {
451
451
  const l = n.current;
@@ -478,13 +478,13 @@ const ve = (e) => `ds.editors.markdown.crepe.${e}`, Yn = (e) => `ds.editors.mark
478
478
  if (!n.ok)
479
479
  throw new Error(`Asset download failed (${n.status})`);
480
480
  const r = await n.blob();
481
- return Fn(r);
482
- }, Fn = (e) => new Promise((t, n) => {
481
+ return Dn(r);
482
+ }, Dn = (e) => new Promise((t, n) => {
483
483
  const r = new FileReader();
484
484
  r.onload = () => {
485
485
  typeof r.result == "string" ? t(r.result) : n(new Error("FileReader returned no data URL"));
486
486
  }, r.onerror = () => n(r.error ?? new Error("FileReader failed")), r.readAsDataURL(e);
487
- }), Ln = b("div")(({ theme: e }) => ({
487
+ }), Fn = b("div")(({ theme: e }) => ({
488
488
  display: "flex",
489
489
  flexDirection: "column",
490
490
  gap: i(e.design.space[4]),
@@ -496,7 +496,7 @@ const ve = (e) => `ds.editors.markdown.crepe.${e}`, Yn = (e) => `ds.editors.mark
496
496
  justifyContent: "flex-end",
497
497
  gap: i(e.design.space[2]),
498
498
  "& > [data-leading]": { marginRight: "auto" }
499
- })), ln = "personal", cn = "org:", un = "project:", Fa = 120, yo = Nn(() => [
499
+ })), ln = "personal", cn = "org:", un = "project:", Fa = 120, yo = Rn(() => [
500
500
  Pe.SIGNATURE,
501
501
  Pe.INITIALS,
502
502
  Pe.STAMP
@@ -570,7 +570,7 @@ function xo({
570
570
  ] }),
571
571
  children: /* @__PURE__ */ T(za, { children: [
572
572
  y && /* @__PURE__ */ o(
573
- In,
573
+ kn,
574
574
  {
575
575
  label: M("ds.editors.pdf.signature.save.scope"),
576
576
  value: h,
@@ -602,7 +602,7 @@ function xo({
602
602
  }
603
603
  ),
604
604
  /* @__PURE__ */ o(
605
- In,
605
+ kn,
606
606
  {
607
607
  label: M("ds.editors.pdf.signature.save.kind"),
608
608
  value: v,
@@ -640,7 +640,7 @@ function xo({
640
640
  )
641
641
  ] });
642
642
  }
643
- const Tn = 460, Pn = 180, _a = {
643
+ const In = 460, Sn = 180, _a = {
644
644
  thin: 1.5,
645
645
  medium: 2.5,
646
646
  thick: 4
@@ -676,7 +676,7 @@ const Tn = 460, Pn = 180, _a = {
676
676
  position: "relative",
677
677
  alignSelf: "center",
678
678
  width: "100%",
679
- maxWidth: i(Tn),
679
+ maxWidth: i(In),
680
680
  backgroundColor: t.paper,
681
681
  border: Q(t["border.subtle"]),
682
682
  borderRadius: i(n.md),
@@ -693,7 +693,7 @@ const Tn = 460, Pn = 180, _a = {
693
693
  position: "absolute",
694
694
  left: "8%",
695
695
  right: "8%",
696
- bottom: `${Wa / Pn * 100}%`,
696
+ bottom: `${Wa / Sn * 100}%`,
697
697
  borderTop: `1px dashed ${e.design.tokens["paper.on"]}`,
698
698
  opacity: 0.15,
699
699
  pointerEvents: "none"
@@ -704,7 +704,7 @@ function Va({
704
704
  onSave: n,
705
705
  assetPalette: r
706
706
  }) {
707
- const s = J(), d = j(null), l = j(null), [p, v] = L(Un[0]), [g, h] = L(
707
+ const s = J(), d = j(null), l = j(null), [p, v] = L(Hn[0]), [g, h] = L(
708
708
  "medium"
709
709
  /* Medium */
710
710
  ), [c, k] = L(!0), [E, w] = L(null), P = (D) => {
@@ -726,7 +726,7 @@ function Va({
726
726
  l.current !== null && d.current !== null && w(d.current.toDataURL("image/png")), l.current = null;
727
727
  }, M = _(() => {
728
728
  var D, R;
729
- (R = (D = d.current) == null ? void 0 : D.getContext("2d")) == null || R.clearRect(0, 0, Tn, Pn), k(!0), w(null);
729
+ (R = (D = d.current) == null ? void 0 : D.getContext("2d")) == null || R.clearRect(0, 0, In, Sn), k(!0), w(null);
730
730
  }, []), f = () => {
731
731
  d.current !== null && e(d.current.toDataURL("image/png"));
732
732
  }, I = s.formatMessage({
@@ -734,7 +734,7 @@ function Va({
734
734
  }), z = s.formatMessage({
735
735
  id: "ds.editors.pdf.signature.draw.stroke-width"
736
736
  });
737
- return /* @__PURE__ */ T(Ln, { children: [
737
+ return /* @__PURE__ */ T(Fn, { children: [
738
738
  /* @__PURE__ */ T(Ba, { children: [
739
739
  /* @__PURE__ */ o(Ha, { children: s.formatMessage({ id: "ds.editors.pdf.signature.draw.title" }) }),
740
740
  /* @__PURE__ */ o(Ua, { children: s.formatMessage({ id: "ds.editors.pdf.signature.draw.helper" }) })
@@ -745,7 +745,7 @@ function Va({
745
745
  {
746
746
  label: I,
747
747
  value: p,
748
- swatches: Un,
748
+ swatches: Hn,
749
749
  onChange: v
750
750
  }
751
751
  ),
@@ -773,8 +773,8 @@ function Va({
773
773
  "canvas",
774
774
  {
775
775
  ref: d,
776
- width: Tn,
777
- height: Pn,
776
+ width: In,
777
+ height: Sn,
778
778
  "aria-label": s.formatMessage({
779
779
  id: "ds.editors.pdf.signature-ui.draw.pad"
780
780
  }),
@@ -810,13 +810,13 @@ function Va({
810
810
  ] })
811
811
  ] });
812
812
  }
813
- const An = "all", ko = Nn(() => [
813
+ const Tn = "all", ko = Rn(() => [
814
814
  Pe.SIGNATURE,
815
815
  Pe.INITIALS,
816
816
  Pe.STAMP,
817
817
  Pe.TEXT_BLOCK
818
- ]), Ya = Nn(() => [
819
- An,
818
+ ]), Ya = Rn(() => [
819
+ Tn,
820
820
  ...ko()
821
821
  ]), Za = (e) => e !== void 0 && (e.personal.length > 0 || (e.organizations ?? []).some((t) => t.items.length > 0) || (e.projects ?? []).some((t) => t.items.length > 0)), qa = b("div")(({ theme: e }) => ({
822
822
  display: "flex",
@@ -922,7 +922,7 @@ function ri({
922
922
  }))
923
923
  ],
924
924
  [e, p, v, g, h]
925
- ), [k, E] = L(c[0].id), [w, P] = L(An), S = c.find((f) => f.id === k) ?? c[0], m = S.items.filter((f) => ko().includes(f.kind)).filter((f) => w === An || f.kind === w), y = async (f) => {
925
+ ), [k, E] = L(c[0].id), [w, P] = L(Tn), S = c.find((f) => f.id === k) ?? c[0], m = S.items.filter((f) => ko().includes(f.kind)).filter((f) => w === Tn || f.kind === w), y = async (f) => {
926
926
  if (f.textContent) {
927
927
  n(f.textContent);
928
928
  return;
@@ -933,10 +933,10 @@ function ri({
933
933
  s == null || s(l("ds.editors.pdf.signature.asset-load-failed"));
934
934
  }
935
935
  }, M = l("ds.editors.pdf.signature-ui.saved.kind");
936
- return /* @__PURE__ */ T(Ln, { children: [
936
+ return /* @__PURE__ */ T(Fn, { children: [
937
937
  /* @__PURE__ */ T(qa, { children: [
938
938
  c.length > 1 && /* @__PURE__ */ o(
939
- In,
939
+ kn,
940
940
  {
941
941
  label: l("ds.editors.pdf.signature.saved.scope-label"),
942
942
  value: S.id,
@@ -1021,7 +1021,7 @@ function li({
1021
1021
  if (P !== void 0) {
1022
1022
  h(null), v(!0);
1023
1023
  try {
1024
- l(await Fn(P));
1024
+ l(await Dn(P));
1025
1025
  } catch (S) {
1026
1026
  h(
1027
1027
  S instanceof Error ? S.message : c("ds.editors.pdf.signature.upload.error.read-failed")
@@ -1042,7 +1042,7 @@ function li({
1042
1042
  }
1043
1043
  ) });
1044
1044
  };
1045
- return /* @__PURE__ */ T(Ln, { children: [
1045
+ return /* @__PURE__ */ T(Fn, { children: [
1046
1046
  /* @__PURE__ */ o(
1047
1047
  ho,
1048
1048
  {
@@ -1230,7 +1230,7 @@ const gi = b(en)(({ theme: e }) => {
1230
1230
  ...Mt(e)
1231
1231
  };
1232
1232
  });
1233
- function qn({
1233
+ function Zn({
1234
1234
  icon: e,
1235
1235
  label: t,
1236
1236
  onClick: n,
@@ -1286,11 +1286,11 @@ const fi = (e, t) => {
1286
1286
  (s) => r(s.id, s.name, s.items, s.avatar)
1287
1287
  )
1288
1288
  ].filter((s) => s.signatures.length > 0 || s.texts.length > 0);
1289
- }, Jn = b("div")(({ theme: e }) => ({
1289
+ }, qn = b("div")(({ theme: e }) => ({
1290
1290
  display: "flex",
1291
1291
  flexDirection: "column",
1292
1292
  gap: i(e.design.space[2])
1293
- })), Qn = b("div")(({ theme: e }) => {
1293
+ })), Jn = b("div")(({ theme: e }) => {
1294
1294
  const { tokens: t, space: n, typeScale: r } = e.design;
1295
1295
  return {
1296
1296
  display: "flex",
@@ -1305,7 +1305,7 @@ const fi = (e, t) => {
1305
1305
  "& > *": { width: i(n[4]), height: i(n[4]) }
1306
1306
  }
1307
1307
  };
1308
- }), eo = b("div")(({ theme: e }) => ({
1308
+ }), Qn = b("div")(({ theme: e }) => ({
1309
1309
  display: "flex",
1310
1310
  flexWrap: "wrap",
1311
1311
  gap: i(e.design.space[2])
@@ -1361,19 +1361,19 @@ function bi({
1361
1361
  }) {
1362
1362
  const d = J();
1363
1363
  return /* @__PURE__ */ T(
1364
- Jn,
1364
+ qn,
1365
1365
  {
1366
1366
  role: "group",
1367
1367
  "aria-label": d.formatMessage({
1368
1368
  id: "ds.editors.pdf.groups.saved-assets"
1369
1369
  }),
1370
1370
  children: [
1371
- /* @__PURE__ */ o(Qn, { children: /* @__PURE__ */ o("span", { children: d.formatMessage({ id: "ds.editors.pdf.insert.saved-title" }) }) }),
1371
+ /* @__PURE__ */ o(Jn, { children: /* @__PURE__ */ o("span", { children: d.formatMessage({ id: "ds.editors.pdf.insert.saved-title" }) }) }),
1372
1372
  /* @__PURE__ */ o(
1373
1373
  tt,
1374
1374
  {
1375
1375
  control: /* @__PURE__ */ o(
1376
- Rn,
1376
+ Mn,
1377
1377
  {
1378
1378
  checked: t,
1379
1379
  onChange: (l, p) => n(p)
@@ -1384,12 +1384,12 @@ function bi({
1384
1384
  })
1385
1385
  }
1386
1386
  ),
1387
- e.map((l) => /* @__PURE__ */ T(Jn, { children: [
1388
- /* @__PURE__ */ T(Qn, { children: [
1387
+ e.map((l) => /* @__PURE__ */ T(qn, { children: [
1388
+ /* @__PURE__ */ T(Jn, { children: [
1389
1389
  l.avatar !== void 0 && /* @__PURE__ */ o("span", { children: l.avatar }),
1390
1390
  /* @__PURE__ */ o("span", { children: l.label })
1391
1391
  ] }),
1392
- l.signatures.length > 0 && /* @__PURE__ */ o(eo, { children: l.signatures.map((p) => /* @__PURE__ */ o(
1392
+ l.signatures.length > 0 && /* @__PURE__ */ o(Qn, { children: l.signatures.map((p) => /* @__PURE__ */ o(
1393
1393
  hi,
1394
1394
  {
1395
1395
  title: p.name,
@@ -1399,7 +1399,7 @@ function bi({
1399
1399
  },
1400
1400
  p.id
1401
1401
  )) }),
1402
- l.texts.length > 0 && /* @__PURE__ */ o(eo, { children: l.texts.map((p) => /* @__PURE__ */ T(
1402
+ l.texts.length > 0 && /* @__PURE__ */ o(Qn, { children: l.texts.map((p) => /* @__PURE__ */ T(
1403
1403
  mi,
1404
1404
  {
1405
1405
  title: p.name,
@@ -1536,7 +1536,7 @@ const vi = [
1536
1536
  fontSize: i(e.design.typeScale.small),
1537
1537
  color: e.design.tokens["text.secondary"]
1538
1538
  }));
1539
- function En({
1539
+ function Pn({
1540
1540
  label: e,
1541
1541
  children: t
1542
1542
  }) {
@@ -1545,7 +1545,7 @@ function En({
1545
1545
  t
1546
1546
  ] });
1547
1547
  }
1548
- const zn = Xo;
1548
+ const Ln = Xo;
1549
1549
  function xi({ settings: e, onChange: t }) {
1550
1550
  const n = J();
1551
1551
  return /* @__PURE__ */ T(ot, { children: [
@@ -1554,12 +1554,12 @@ function xi({ settings: e, onChange: t }) {
1554
1554
  {
1555
1555
  label: n.formatMessage({ id: "ds.editors.pdf.draw.color" }),
1556
1556
  value: e.drawColor,
1557
- swatches: zn,
1557
+ swatches: Ln,
1558
1558
  onChange: (r) => t({ drawColor: r })
1559
1559
  }
1560
1560
  ),
1561
1561
  /* @__PURE__ */ o(
1562
- On,
1562
+ En,
1563
1563
  {
1564
1564
  label: n.formatMessage({ id: "ds.editors.pdf.draw.width" }),
1565
1565
  value: e.drawStrokeWidth,
@@ -1612,7 +1612,7 @@ function Ci({
1612
1612
  ), v = (g) => {
1613
1613
  g ? n(
1614
1614
  Ce({ opId: pe(), type: H.FLATTEN })
1615
- ) : p && n(yn(p.opId));
1615
+ ) : p && n(wn(p.opId));
1616
1616
  };
1617
1617
  return /* @__PURE__ */ o(ki, { children: /* @__PURE__ */ T(ot, { children: [
1618
1618
  /* @__PURE__ */ o(gt, { children: r.formatMessage(
@@ -1626,7 +1626,7 @@ function Ci({
1626
1626
  tt,
1627
1627
  {
1628
1628
  control: /* @__PURE__ */ o(
1629
- Mn,
1629
+ On,
1630
1630
  {
1631
1631
  checked: h === !0,
1632
1632
  onChange: (k) => l(g.name, k.target.checked)
@@ -1638,7 +1638,7 @@ function Ci({
1638
1638
  );
1639
1639
  const c = typeof h == "string" ? h : "";
1640
1640
  return g.kind === "dropdown" ? /* @__PURE__ */ o(
1641
- Vn,
1641
+ Xn,
1642
1642
  {
1643
1643
  select: !0,
1644
1644
  label: g.name,
@@ -1671,7 +1671,7 @@ function Ci({
1671
1671
  // Keyed by the current value so undo and redo remount the input with the right text;
1672
1672
  // typing stays local until blur.
1673
1673
  /* @__PURE__ */ o(
1674
- Vn,
1674
+ Xn,
1675
1675
  {
1676
1676
  label: g.name,
1677
1677
  defaultValue: c,
@@ -1682,12 +1682,12 @@ function Ci({
1682
1682
  )
1683
1683
  );
1684
1684
  }),
1685
- /* @__PURE__ */ o(Sn, {}),
1685
+ /* @__PURE__ */ o(Cn, {}),
1686
1686
  /* @__PURE__ */ o(
1687
1687
  tt,
1688
1688
  {
1689
1689
  control: /* @__PURE__ */ o(
1690
- Rn,
1690
+ Mn,
1691
1691
  {
1692
1692
  checked: !!p,
1693
1693
  onChange: (g, h) => v(h)
@@ -1746,7 +1746,7 @@ const Pi = ["rect", "ellipse", "line", "arrow"];
1746
1746
  function Ai({ settings: e, onChange: t }) {
1747
1747
  const n = J(), r = e.shapeKind === "rect" || e.shapeKind === "ellipse", s = n.formatMessage({ id: "ds.editors.pdf.shape.kind" }), d = n.formatMessage({ id: "ds.editors.pdf.shape.fill" });
1748
1748
  return /* @__PURE__ */ T(ot, { children: [
1749
- /* @__PURE__ */ o(En, { label: s, children: /* @__PURE__ */ o(
1749
+ /* @__PURE__ */ o(Pn, { label: s, children: /* @__PURE__ */ o(
1750
1750
  Et,
1751
1751
  {
1752
1752
  ariaLabel: s,
@@ -1765,11 +1765,11 @@ function Ai({ settings: e, onChange: t }) {
1765
1765
  {
1766
1766
  label: n.formatMessage({ id: "ds.editors.pdf.draw.color" }),
1767
1767
  value: e.drawColor,
1768
- swatches: zn,
1768
+ swatches: Ln,
1769
1769
  onChange: (l) => t({ drawColor: l })
1770
1770
  }
1771
1771
  ),
1772
- r && /* @__PURE__ */ o(En, { label: d, children: /* @__PURE__ */ o(
1772
+ r && /* @__PURE__ */ o(Pn, { label: d, children: /* @__PURE__ */ o(
1773
1773
  Et,
1774
1774
  {
1775
1775
  ariaLabel: d,
@@ -1794,7 +1794,7 @@ function Ai({ settings: e, onChange: t }) {
1794
1794
  }
1795
1795
  ) }),
1796
1796
  /* @__PURE__ */ o(
1797
- On,
1797
+ En,
1798
1798
  {
1799
1799
  label: n.formatMessage({ id: "ds.editors.pdf.draw.width" }),
1800
1800
  value: e.drawStrokeWidth,
@@ -1831,7 +1831,7 @@ function Mi({ settings: e, onChange: t }) {
1831
1831
  const n = J(), r = n.formatMessage({ id: "ds.editors.pdf.text.font" });
1832
1832
  return /* @__PURE__ */ T(ot, { children: [
1833
1833
  /* @__PURE__ */ o(gt, { children: n.formatMessage({ id: "ds.editors.pdf.text.hint-short" }) }),
1834
- /* @__PURE__ */ o(En, { label: r, children: /* @__PURE__ */ o(
1834
+ /* @__PURE__ */ o(Pn, { label: r, children: /* @__PURE__ */ o(
1835
1835
  Et,
1836
1836
  {
1837
1837
  ariaLabel: r,
@@ -1846,7 +1846,7 @@ function Mi({ settings: e, onChange: t }) {
1846
1846
  }
1847
1847
  ) }),
1848
1848
  /* @__PURE__ */ o(
1849
- On,
1849
+ En,
1850
1850
  {
1851
1851
  label: n.formatMessage({ id: "ds.editors.pdf.text.size" }),
1852
1852
  value: e.textSize,
@@ -1862,7 +1862,7 @@ function Mi({ settings: e, onChange: t }) {
1862
1862
  {
1863
1863
  label: n.formatMessage({ id: "ds.editors.pdf.draw.color" }),
1864
1864
  value: e.textColor,
1865
- swatches: zn,
1865
+ swatches: Ln,
1866
1866
  onChange: (s) => t({ textColor: s })
1867
1867
  }
1868
1868
  )
@@ -2041,7 +2041,7 @@ function Fi({
2041
2041
  e.tools.map((c) => {
2042
2042
  const k = pt[c].icon;
2043
2043
  return /* @__PURE__ */ o(
2044
- qn,
2044
+ Zn,
2045
2045
  {
2046
2046
  testId: `pdf-tool-${c}`,
2047
2047
  icon: /* @__PURE__ */ o(k, {}),
@@ -2055,7 +2055,7 @@ function Fi({
2055
2055
  v.map((c) => {
2056
2056
  const { run: k } = c;
2057
2057
  return /* @__PURE__ */ o(
2058
- qn,
2058
+ Zn,
2059
2059
  {
2060
2060
  testId: `pdf-action-${c.id}`,
2061
2061
  icon: c.icon,
@@ -2069,7 +2069,7 @@ function Fi({
2069
2069
  );
2070
2070
  }),
2071
2071
  g.length > 0 && /* @__PURE__ */ T(Oe, { children: [
2072
- /* @__PURE__ */ o(Sn, {}),
2072
+ /* @__PURE__ */ o(Cn, {}),
2073
2073
  /* @__PURE__ */ o(
2074
2074
  bi,
2075
2075
  {
@@ -2082,7 +2082,7 @@ function Fi({
2082
2082
  )
2083
2083
  ] }),
2084
2084
  h && /* @__PURE__ */ T(Oe, { children: [
2085
- /* @__PURE__ */ o(Sn, {}),
2085
+ /* @__PURE__ */ o(Cn, {}),
2086
2086
  /* @__PURE__ */ o(
2087
2087
  "section",
2088
2088
  {
@@ -2548,7 +2548,7 @@ const Hi = {
2548
2548
  }
2549
2549
  );
2550
2550
  Io.displayName = "PdfCanvas";
2551
- const to = {
2551
+ const eo = {
2552
2552
  sans: "Helvetica, Arial, sans-serif",
2553
2553
  serif: '"Times New Roman", Times, serif',
2554
2554
  mono: '"Courier New", Courier, monospace'
@@ -2574,7 +2574,7 @@ const to = {
2574
2574
  // The chip holds a 44 px target on touch screens: lift it clear of the annotation.
2575
2575
  [Me.down(Ae.Tablet)]: { top: -48 }
2576
2576
  };
2577
- }), Ji = b(Dn)(({ theme: e }) => ({
2577
+ }), Ji = b(Nn)(({ theme: e }) => ({
2578
2578
  padding: i(e.design.space[1]),
2579
2579
  color: e.design.tokens["status.danger"],
2580
2580
  "& svg": { width: 14, height: 14 },
@@ -2596,7 +2596,7 @@ const to = {
2596
2596
  height: i(r.touchTarget / 2)
2597
2597
  }
2598
2598
  };
2599
- }), no = b("div", {
2599
+ }), to = b("div", {
2600
2600
  shouldForwardProp: (e) => e !== "ownerState"
2601
2601
  })(({ theme: e, ownerState: t }) => {
2602
2602
  const { tokens: n, radii: r } = e.design, { selected: s, dragging: d, erasing: l, tinted: p } = t;
@@ -2625,7 +2625,7 @@ const to = {
2625
2625
  boxShadow: `0 0 0 3px ${ft(t.accent)}`
2626
2626
  }
2627
2627
  };
2628
- }), oo = ({ label: e, onDelete: t }) => /* @__PURE__ */ o(
2628
+ }), no = ({ label: e, onDelete: t }) => /* @__PURE__ */ o(
2629
2629
  qi,
2630
2630
  {
2631
2631
  onPointerDown: (n) => n.stopPropagation(),
@@ -2677,9 +2677,9 @@ const to = {
2677
2677
  a = !0;
2678
2678
  };
2679
2679
  }, [p]);
2680
- const ae = xn(I), de = kn(n, r, ae), ee = _(
2680
+ const ae = vn(I), de = yn(n, r, ae), ee = _(
2681
2681
  (a, x) => {
2682
- const N = xn(I), O = kn(n, r, N);
2682
+ const N = vn(I), O = yn(n, r, N);
2683
2683
  return Yo(
2684
2684
  a / f,
2685
2685
  x / f,
@@ -2704,7 +2704,7 @@ const to = {
2704
2704
  return;
2705
2705
  const a = $.text.trim(), { isExisting: x, opId: N } = $;
2706
2706
  if (Ie(null), te(null), !a) {
2707
- x && c(yn(N));
2707
+ x && c(wn(N));
2708
2708
  return;
2709
2709
  }
2710
2710
  c(
@@ -2737,7 +2737,7 @@ const to = {
2737
2737
  if (a.defaultPrevented)
2738
2738
  return;
2739
2739
  if (!q) {
2740
- c(Cn(t));
2740
+ c(xn(t));
2741
2741
  return;
2742
2742
  }
2743
2743
  if ($)
@@ -2756,7 +2756,7 @@ const to = {
2756
2756
  color: w,
2757
2757
  fontFamily: S
2758
2758
  };
2759
- c(g ? Gn(A, h) : Ce(A)), c(Zt(null)), c(At(!1)), c(We("select"));
2759
+ c(g ? Un(A, h) : Ce(A)), c(Zt(null)), c(At(!1)), c(We("select"));
2760
2760
  return;
2761
2761
  }
2762
2762
  Ie({
@@ -2782,7 +2782,7 @@ const to = {
2782
2782
  heightPt: ne,
2783
2783
  source: { kind: "INLINE", storageKey: p }
2784
2784
  };
2785
- c(g ? Gn(he, h) : Ce(he)), c(qt(null)), c(At(!1)), c(We("select"));
2785
+ c(g ? Un(he, h) : Ce(he)), c(qt(null)), c(At(!1)), c(We("select"));
2786
2786
  }
2787
2787
  },
2788
2788
  [
@@ -2814,7 +2814,7 @@ const to = {
2814
2814
  }), K(null));
2815
2815
  }, []), me = _(
2816
2816
  (a) => {
2817
- c(yn(a)), K((x) => x === a ? null : x);
2817
+ c(wn(a)), K((x) => x === a ? null : x);
2818
2818
  },
2819
2819
  [c]
2820
2820
  );
@@ -2836,7 +2836,7 @@ const to = {
2836
2836
  var U, re;
2837
2837
  if (x.type !== H.ANNOTATE_TEXT && x.type !== H.ANNOTATE_IMAGE)
2838
2838
  return;
2839
- a.stopPropagation(), (re = (U = a.currentTarget).setPointerCapture) == null || re.call(U, a.pointerId), q || c(Cn(t));
2839
+ a.stopPropagation(), (re = (U = a.currentTarget).setPointerCapture) == null || re.call(U, a.pointerId), q || c(xn(t));
2840
2840
  const { x: N, y: O } = Le(a), A = ee(N, O);
2841
2841
  ge.current = { dx: A.x - x.x, dy: A.y - x.y }, Se(x.opId), xe.current = !1;
2842
2842
  },
@@ -2862,7 +2862,7 @@ const to = {
2862
2862
  xe.current = !0, le = !0;
2863
2863
  }
2864
2864
  c(
2865
- le ? Xt(A.opId, { ...A, x: ne, y: he }) : Kn(A.opId, { ...A, x: ne, y: he })
2865
+ le ? Xt(A.opId, { ...A, x: ne, y: he }) : Gn(A.opId, { ...A, x: ne, y: he })
2866
2866
  );
2867
2867
  }, N = () => {
2868
2868
  xe.current || K(ie), Se(null);
@@ -2902,7 +2902,7 @@ const to = {
2902
2902
  const De = A.corner === "sw" || A.corner === "nw" ? A.ax - le : A.ax, Te = A.corner === "nw" || A.corner === "ne" ? A.ay - ce : A.ay, Ze = { ...O, x: De, y: Te, widthPt: le, heightPt: ce };
2903
2903
  let Ue = !1;
2904
2904
  mt.current || (mt.current = !0, Ue = !0), c(
2905
- Ue ? Xt(O.opId, Ze) : Kn(O.opId, Ze)
2905
+ Ue ? Xt(O.opId, Ze) : Gn(O.opId, Ze)
2906
2906
  );
2907
2907
  }, x = () => Rt(null);
2908
2908
  return window.addEventListener("pointermove", a), window.addEventListener("pointerup", x), window.addEventListener("pointercancel", x), () => {
@@ -3216,7 +3216,7 @@ const to = {
3216
3216
  !1,
3217
3217
  d === "highlight"
3218
3218
  )),
3219
- tn.map((a) => /* @__PURE__ */ T(vn.Fragment, { children: [
3219
+ tn.map((a) => /* @__PURE__ */ T(bn.Fragment, { children: [
3220
3220
  /* @__PURE__ */ o(
3221
3221
  "path",
3222
3222
  {
@@ -3274,7 +3274,7 @@ const to = {
3274
3274
  nn.map((a) => {
3275
3275
  const x = ye === a.opId, N = ie === a.opId, O = a.source.kind === "INLINE" ? a.source.storageKey : null;
3276
3276
  return O ? /* @__PURE__ */ T(
3277
- no,
3277
+ to,
3278
3278
  {
3279
3279
  ownerState: {
3280
3280
  selected: x,
@@ -3326,7 +3326,7 @@ const to = {
3326
3326
  A
3327
3327
  )),
3328
3328
  x && !se && /* @__PURE__ */ o(
3329
- oo,
3329
+ no,
3330
3330
  {
3331
3331
  label: Lt,
3332
3332
  onDelete: () => me(a.opId)
@@ -3340,7 +3340,7 @@ const to = {
3340
3340
  st.map((a) => {
3341
3341
  const x = ye === a.opId, N = ie === a.opId;
3342
3342
  return /* @__PURE__ */ T(
3343
- no,
3343
+ to,
3344
3344
  {
3345
3345
  ownerState: {
3346
3346
  selected: x,
@@ -3361,7 +3361,7 @@ const to = {
3361
3361
  left: Fe(a.x),
3362
3362
  top: Fe(a.y) - a.fontSize * f,
3363
3363
  fontSize: a.fontSize * f,
3364
- fontFamily: to[a.fontFamily ?? "sans"],
3364
+ fontFamily: eo[a.fontFamily ?? "sans"],
3365
3365
  color: a.color,
3366
3366
  // Match the bake: watermark text is translucent + rotated (pdf-lib
3367
3367
  // rotates CCW around the baseline anchor → CSS rotate from bottom-left).
@@ -3376,7 +3376,7 @@ const to = {
3376
3376
  children: [
3377
3377
  a.text,
3378
3378
  x && /* @__PURE__ */ o(
3379
- oo,
3379
+ no,
3380
3380
  {
3381
3381
  label: Lt,
3382
3382
  onDelete: () => me(a.opId)
@@ -3413,7 +3413,7 @@ const to = {
3413
3413
  sx: {
3414
3414
  fontSize: $.fontSize * f,
3415
3415
  lineHeight: 1.15,
3416
- fontFamily: to[$.fontFamily],
3416
+ fontFamily: eo[$.fontFamily],
3417
3417
  color: $.color,
3418
3418
  minWidth: 80,
3419
3419
  "& input": {
@@ -3539,7 +3539,7 @@ const to = {
3539
3539
  borderRadius: i(r.sm),
3540
3540
  padding: i(n[1])
3541
3541
  };
3542
- }), ro = b(Dn, {
3542
+ }), oo = b(Nn, {
3543
3543
  shouldForwardProp: (e) => e !== "danger"
3544
3544
  })(({ theme: e, danger: t }) => {
3545
3545
  const { tokens: n, space: r } = e.design;
@@ -3676,7 +3676,7 @@ const to = {
3676
3676
  F = !0;
3677
3677
  };
3678
3678
  }, [I, M, D]);
3679
- const Y = () => v(Cn(s)), ae = async (F) => {
3679
+ const Y = () => v(xn(s)), ae = async (F) => {
3680
3680
  F.stopPropagation(), await h({
3681
3681
  title: g.formatMessage({
3682
3682
  id: "ds.editors.pdf.page.confirm-delete.title"
@@ -3757,7 +3757,7 @@ const to = {
3757
3757
  ),
3758
3758
  /* @__PURE__ */ T(ds, { className: "page-actions", onClick: (F) => F.stopPropagation(), children: [
3759
3759
  /* @__PURE__ */ o(
3760
- ro,
3760
+ oo,
3761
3761
  {
3762
3762
  size: "small",
3763
3763
  onClick: de,
@@ -3769,7 +3769,7 @@ const to = {
3769
3769
  }
3770
3770
  ),
3771
3771
  /* @__PURE__ */ o(
3772
- ro,
3772
+ oo,
3773
3773
  {
3774
3774
  size: "small",
3775
3775
  danger: !0,
@@ -3904,7 +3904,7 @@ const to = {
3904
3904
  /* @__PURE__ */ o(hs, { children: Array.from({ length: t.numPages }, (w, P) => /* @__PURE__ */ o(
3905
3905
  tt,
3906
3906
  {
3907
- control: /* @__PURE__ */ o(Mn, { checked: h.has(P), onChange: () => k(P) }),
3907
+ control: /* @__PURE__ */ o(On, { checked: h.has(P), onChange: () => k(P) }),
3908
3908
  label: v.formatMessage(
3909
3909
  { id: "ds.editors.pdf.insert-dialog.page-label" },
3910
3910
  { num: P + 1 }
@@ -4118,7 +4118,7 @@ const to = {
4118
4118
  }
4119
4119
  ) })
4120
4120
  ] });
4121
- }, Ss = b("div", {
4121
+ }, ro = je * 0.5, An = je * 3, ao = 1.25, Ss = (e, t) => Math.min(An, e / t), Ts = b("div", {
4122
4122
  shouldForwardProp: (e) => e !== "compact" && e !== "sidebarWidth"
4123
4123
  })(
4124
4124
  ({ theme: e, compact: t, sidebarWidth: n }) => {
@@ -4147,7 +4147,7 @@ const to = {
4147
4147
  pointerEvents: "none"
4148
4148
  };
4149
4149
  }
4150
- ), ao = b("div", {
4150
+ ), io = b("div", {
4151
4151
  shouldForwardProp: (e) => e !== "compact"
4152
4152
  })(({ theme: e, compact: t }) => {
4153
4153
  const { tokens: n, space: r, elevations: s } = e.design;
@@ -4162,12 +4162,12 @@ const to = {
4162
4162
  boxShadow: s.overlay,
4163
4163
  pointerEvents: "auto"
4164
4164
  };
4165
- }), It = b(Dn)(({ theme: e }) => ({
4165
+ }), It = b(Nn)(({ theme: e }) => ({
4166
4166
  color: e.design.tokens["text.secondary"],
4167
4167
  "&:hover": { backgroundColor: e.design.tokens["bg.hover"] },
4168
4168
  "&.Mui-focusVisible": Xe(e),
4169
4169
  ...Qt(e)
4170
- })), Ts = b("input")(({ theme: e }) => {
4170
+ })), Ps = b("input")(({ theme: e }) => {
4171
4171
  const { tokens: t, fonts: n, typeScale: r, radii: s } = e.design;
4172
4172
  return {
4173
4173
  width: "3ch",
@@ -4184,18 +4184,18 @@ const to = {
4184
4184
  // Two digits are narrower than a finger: below 768 px the field is 44 px wide too.
4185
4185
  ...Qt(e)
4186
4186
  };
4187
- }), Ps = b("span")(({ theme: e }) => ({
4187
+ }), As = b("span")(({ theme: e }) => ({
4188
4188
  color: e.design.tokens["text.secondary"],
4189
4189
  fontSize: i(e.design.typeScale.small),
4190
4190
  whiteSpace: "nowrap"
4191
- })), As = b("div", {
4191
+ })), Es = b("div", {
4192
4192
  shouldForwardProp: (e) => e !== "compact"
4193
4193
  })(({ theme: e, compact: t }) => ({
4194
4194
  display: "flex",
4195
4195
  alignItems: "center",
4196
4196
  gap: i(e.design.space[1]),
4197
4197
  padding: t ? 0 : `0 ${i(e.design.space[1])}`
4198
- })), Es = b("button")(({ theme: e }) => {
4198
+ })), Os = b("button")(({ theme: e }) => {
4199
4199
  const { tokens: t, fonts: n, typeScale: r, radii: s } = e.design;
4200
4200
  return {
4201
4201
  minWidth: 46,
@@ -4212,12 +4212,12 @@ const to = {
4212
4212
  "&:focus-visible": Xe(e),
4213
4213
  ...Mt(e)
4214
4214
  };
4215
- }), Os = b("span")(({ theme: e }) => ({
4215
+ }), Ms = b("span")(({ theme: e }) => ({
4216
4216
  alignSelf: "stretch",
4217
4217
  width: 1,
4218
4218
  margin: `0 ${i(e.design.space[1])}`,
4219
4219
  backgroundColor: e.design.tokens["border.subtle"]
4220
- })), Ms = ({
4220
+ })), Rs = ({
4221
4221
  zoom: e,
4222
4222
  onZoomIn: t,
4223
4223
  onZoomOut: n,
@@ -4240,13 +4240,13 @@ const to = {
4240
4240
  !Number.isNaN(m) && m >= 1 && m <= v ? g(m - 1) : w(String(p + 1));
4241
4241
  }, S = (m) => k.formatMessage({ id: m });
4242
4242
  return /* @__PURE__ */ T(
4243
- Ss,
4243
+ Ts,
4244
4244
  {
4245
4245
  compact: h,
4246
4246
  sidebarWidth: c,
4247
4247
  "data-testid": "pdf-viewer-controls",
4248
4248
  children: [
4249
- v > 1 && /* @__PURE__ */ T(ao, { compact: h, children: [
4249
+ v > 1 && /* @__PURE__ */ T(io, { compact: h, children: [
4250
4250
  /* @__PURE__ */ o(
4251
4251
  It,
4252
4252
  {
@@ -4258,9 +4258,9 @@ const to = {
4258
4258
  children: /* @__PURE__ */ o(Ta, { fontSize: "small", "aria-hidden": !0 })
4259
4259
  }
4260
4260
  ),
4261
- /* @__PURE__ */ T(As, { compact: h, children: [
4261
+ /* @__PURE__ */ T(Es, { compact: h, children: [
4262
4262
  /* @__PURE__ */ o(
4263
- Ts,
4263
+ Ps,
4264
4264
  {
4265
4265
  inputMode: "numeric",
4266
4266
  value: E,
@@ -4278,7 +4278,7 @@ const to = {
4278
4278
  )
4279
4279
  }
4280
4280
  ),
4281
- /* @__PURE__ */ T(Ps, { children: [
4281
+ /* @__PURE__ */ T(As, { children: [
4282
4282
  "/ ",
4283
4283
  k.formatNumber(v)
4284
4284
  ] })
@@ -4295,7 +4295,7 @@ const to = {
4295
4295
  }
4296
4296
  )
4297
4297
  ] }),
4298
- /* @__PURE__ */ T(ao, { compact: h, children: [
4298
+ /* @__PURE__ */ T(io, { compact: h, children: [
4299
4299
  /* @__PURE__ */ o(
4300
4300
  It,
4301
4301
  {
@@ -4308,7 +4308,7 @@ const to = {
4308
4308
  }
4309
4309
  ),
4310
4310
  /* @__PURE__ */ o(
4311
- Es,
4311
+ Os,
4312
4312
  {
4313
4313
  type: "button",
4314
4314
  title: S("ds.editors.pdf.viewer.reset-zoom"),
@@ -4331,7 +4331,7 @@ const to = {
4331
4331
  children: /* @__PURE__ */ o(Ia, { fontSize: "small", "aria-hidden": !0 })
4332
4332
  }
4333
4333
  ),
4334
- /* @__PURE__ */ o(Os, { "aria-hidden": !0 }),
4334
+ /* @__PURE__ */ o(Ms, { "aria-hidden": !0 }),
4335
4335
  /* @__PURE__ */ o(
4336
4336
  It,
4337
4337
  {
@@ -4346,14 +4346,14 @@ const to = {
4346
4346
  ]
4347
4347
  }
4348
4348
  );
4349
- }, Rs = 800, io = [], hn = je * 0.5, mn = je * 3, so = 1.25, Ns = 48, Ds = { wpt: 595.28, hpt: 841.89 }, jt = b("div")(({ theme: e }) => ({
4349
+ }, Ns = 800, so = [], Ds = 48, Fs = { wpt: 595.28, hpt: 841.89 }, jt = b("div")(({ theme: e }) => ({
4350
4350
  display: "flex",
4351
4351
  flexDirection: "column",
4352
4352
  height: "100%",
4353
4353
  overflow: "hidden",
4354
4354
  fontFamily: e.design.fonts.sans,
4355
4355
  color: e.design.tokens["text.primary"]
4356
- })), bn = b("div")(({ theme: e }) => {
4356
+ })), hn = b("div")(({ theme: e }) => {
4357
4357
  const { tokens: t, space: n, typeScale: r } = e.design;
4358
4358
  return {
4359
4359
  display: "flex",
@@ -4367,17 +4367,17 @@ const to = {
4367
4367
  fontSize: i(r.body),
4368
4368
  color: t["text.secondary"]
4369
4369
  };
4370
- }), Fs = b("h2")(({ theme: e }) => ({
4370
+ }), Ls = b("h2")(({ theme: e }) => ({
4371
4371
  margin: 0,
4372
4372
  fontSize: i(e.design.typeScale.sectionTitle),
4373
4373
  fontWeight: _e.semibold,
4374
4374
  color: e.design.tokens["text.primary"]
4375
- })), Ls = b("p")({ margin: 0, maxWidth: 420 }), zs = b("div")({ width: "100%", maxWidth: 520 }), _s = b("div")({ width: "100%", maxWidth: 320 }), $s = b("div")(({ theme: e }) => ({
4375
+ })), zs = b("p")({ margin: 0, maxWidth: 420 }), _s = b("div")({ width: "100%", maxWidth: 520 }), $s = b("div")({ width: "100%", maxWidth: 320 }), Ws = b("div")(({ theme: e }) => ({
4376
4376
  display: "flex",
4377
4377
  flexWrap: "wrap",
4378
4378
  justifyContent: "center",
4379
4379
  gap: i(e.design.space[2])
4380
- })), Ws = b("div")(({ theme: e }) => {
4380
+ })), Bs = b("div")(({ theme: e }) => {
4381
4381
  const { tokens: t, space: n } = e.design;
4382
4382
  return {
4383
4383
  flex: "none",
@@ -4388,18 +4388,18 @@ const to = {
4388
4388
  backgroundColor: t["bg.surface"],
4389
4389
  borderBottom: Q(t["border.subtle"])
4390
4390
  };
4391
- }), Bs = b("div")({
4391
+ }), Hs = b("div")({
4392
4392
  display: "flex",
4393
4393
  flex: 1,
4394
4394
  minHeight: 0,
4395
4395
  overflow: "hidden",
4396
4396
  position: "relative"
4397
- }), Hs = b("div")(({ theme: e }) => ({
4397
+ }), Us = b("div")(({ theme: e }) => ({
4398
4398
  position: "absolute",
4399
4399
  inset: 0,
4400
4400
  zIndex: 6,
4401
4401
  backgroundColor: e.design.tokens["overlay.scrim"]
4402
- })), Us = b("div", {
4402
+ })), Gs = b("div", {
4403
4403
  shouldForwardProp: (e) => e !== "floating"
4404
4404
  })(
4405
4405
  ({ theme: e, floating: t }) => t ? {
@@ -4411,7 +4411,7 @@ const to = {
4411
4411
  display: "flex",
4412
4412
  boxShadow: e.design.elevations.overlay
4413
4413
  } : { display: "flex" }
4414
- ), Gs = b("div", {
4414
+ ), Ks = b("div", {
4415
4415
  shouldForwardProp: (e) => e !== "offset"
4416
4416
  })(({ theme: e, offset: t }) => ({
4417
4417
  position: "absolute",
@@ -4423,7 +4423,7 @@ const to = {
4423
4423
  display: "flex",
4424
4424
  justifyContent: "center",
4425
4425
  pointerEvents: "none"
4426
- })), Ks = b("div")(({ theme: e }) => {
4426
+ })), js = b("div")(({ theme: e }) => {
4427
4427
  const { tokens: t, space: n, elevations: r } = e.design;
4428
4428
  return {
4429
4429
  pointerEvents: "none",
@@ -4443,7 +4443,7 @@ const to = {
4443
4443
  pointerEvents: "auto"
4444
4444
  }
4445
4445
  };
4446
- }), js = b("img")(({ theme: e }) => {
4446
+ }), Xs = b("img")(({ theme: e }) => {
4447
4447
  const { tokens: t, radii: n } = e.design;
4448
4448
  return {
4449
4449
  flex: "none",
@@ -4454,7 +4454,7 @@ const to = {
4454
4454
  border: Q(t["border.subtle"]),
4455
4455
  borderRadius: i(n.sm)
4456
4456
  };
4457
- }), Xs = b("span")(({ theme: e }) => {
4457
+ }), Vs = b("span")(({ theme: e }) => {
4458
4458
  const { tokens: t, space: n, radii: r, typeScale: s } = e.design;
4459
4459
  return {
4460
4460
  flex: "none",
@@ -4469,7 +4469,7 @@ const to = {
4469
4469
  overflow: "hidden",
4470
4470
  textOverflow: "ellipsis"
4471
4471
  };
4472
- }), Vs = b("span")(({ theme: e }) => ({
4472
+ }), Ys = b("span")(({ theme: e }) => ({
4473
4473
  minWidth: 0,
4474
4474
  fontSize: i(e.design.typeScale.body),
4475
4475
  fontWeight: _e.semibold,
@@ -4480,22 +4480,22 @@ const to = {
4480
4480
  })), lo = b("span")(({ theme: e }) => ({
4481
4481
  alignSelf: "stretch",
4482
4482
  borderLeft: Q(e.design.tokens["border.subtle"])
4483
- })), Ys = b("span")(({ theme: e }) => ({
4483
+ })), Zs = b("span")(({ theme: e }) => ({
4484
4484
  fontSize: i(e.design.typeScale.small),
4485
4485
  color: e.design.tokens["text.secondary"]
4486
- })), Zs = b("input")({ display: "none" }), qs = b("div")(({ theme: e }) => ({
4486
+ })), qs = b("input")({ display: "none" }), Js = b("div")(({ theme: e }) => ({
4487
4487
  display: "flex",
4488
4488
  flexDirection: "column",
4489
4489
  gap: i(e.design.space[3])
4490
- })), Js = b("div")({
4490
+ })), Qs = b("div")({
4491
4491
  display: "flex",
4492
4492
  justifyContent: "flex-end"
4493
- }), Qs = b("div")({
4493
+ }), ed = b("div")({
4494
4494
  display: "flex",
4495
4495
  flexDirection: "column",
4496
4496
  maxHeight: 280,
4497
4497
  overflowY: "auto"
4498
- }), wn = (e, t) => {
4498
+ }), mn = (e, t) => {
4499
4499
  const n = new Blob([new Uint8Array(e)], { type: "application/pdf" }), r = URL.createObjectURL(n);
4500
4500
  try {
4501
4501
  const s = document.createElement("a");
@@ -4504,10 +4504,10 @@ const to = {
4504
4504
  URL.revokeObjectURL(r);
4505
4505
  }
4506
4506
  };
4507
- function xl(e) {
4508
- return /* @__PURE__ */ o(Er, { children: /* @__PURE__ */ o(ed, { ...e }) });
4507
+ function kl(e) {
4508
+ return /* @__PURE__ */ o(Er, { children: /* @__PURE__ */ o(td, { ...e }) });
4509
4509
  }
4510
- function ed({
4510
+ function td({
4511
4511
  source: e,
4512
4512
  mode: t,
4513
4513
  initialOperations: n,
@@ -4530,9 +4530,9 @@ function ed({
4530
4530
  [S]
4531
4531
  ), [y, M] = _o(dr, {
4532
4532
  ...lr,
4533
- operations: n ?? io
4533
+ operations: n ?? so
4534
4534
  }), f = j(
4535
- n ?? io
4535
+ n ?? so
4536
4536
  ), I = j(null);
4537
4537
  X(() => {
4538
4538
  if (!r || f.current === y.operations)
@@ -4545,7 +4545,7 @@ function ed({
4545
4545
  }).catch((C) => {
4546
4546
  console.warn("[PdfEditor] operations flush failed", C);
4547
4547
  });
4548
- }, Rs), () => {
4548
+ }, Ns), () => {
4549
4549
  I.current && (clearTimeout(I.current), I.current = null);
4550
4550
  };
4551
4551
  }, [y.operations, r]);
@@ -4603,11 +4603,11 @@ function ed({
4603
4603
  return { bytes: u, ops: C };
4604
4604
  }, [D, z, y.operations]), Ne = _(async () => {
4605
4605
  const u = await me();
4606
- return u ? jn(u.bytes, u.ops) : null;
4606
+ return u ? Kn(u.bytes, u.ops) : null;
4607
4607
  }, [me]), Be = e.fileName.replace(/\.pdf$/i, ""), [ze, at] = L(je), [vt, He] = L(0), [it, yt] = L(!0), [Dt, st] = L(!0), [tn, nn] = L(0), Ft = j(null), xt = j(null), Ee = Or() === Ae.Mobile, dt = !h && it && !Ee ? So : 0, se = _(() => {
4608
- st(!1), at((u) => Math.min(mn, u * so));
4608
+ st(!1), at((u) => Math.min(An, u * ao));
4609
4609
  }, []), Lt = _(() => {
4610
- st(!1), at((u) => Math.max(hn, u / so));
4610
+ st(!1), at((u) => Math.max(ro, u / ao));
4611
4611
  }, []), Ye = _(() => {
4612
4612
  st(!1), at(je);
4613
4613
  }, []), a = _(() => st(!0), []), x = _((u) => {
@@ -4622,11 +4622,11 @@ function ed({
4622
4622
  (u) => {
4623
4623
  const C = $e.get(u);
4624
4624
  if (!C)
4625
- return Ds;
4626
- const B = kn(
4625
+ return Fs;
4626
+ const B = yn(
4627
4627
  C.w,
4628
4628
  C.h,
4629
- xn(C.rotation)
4629
+ vn(C.rotation)
4630
4630
  );
4631
4631
  return { wpt: B.w / ze, hpt: B.h / ze };
4632
4632
  },
@@ -4647,10 +4647,10 @@ function ed({
4647
4647
  let C = 0;
4648
4648
  for (const be of $e.values())
4649
4649
  C = Math.max(C, be.wpt);
4650
- const B = u.clientWidth - dt - Ns;
4650
+ const B = u.clientWidth - dt - Ds;
4651
4651
  if (C <= 0 || B <= 0)
4652
4652
  return;
4653
- const ue = Math.min(mn, Math.max(hn, B / C));
4653
+ const ue = Ss(B, C);
4654
4654
  at((be) => Math.abs(be - ue) < 1e-3 ? be : ue);
4655
4655
  }, [Dt, $e, dt, tn]), X(() => {
4656
4656
  q.length > 0 && M(vr(q));
@@ -4691,7 +4691,7 @@ function ed({
4691
4691
  color: Je
4692
4692
  };
4693
4693
  });
4694
- u.length > 0 && M(Xn(u));
4694
+ u.length > 0 && M(jn(u));
4695
4695
  }, [Z, O]), [re, ne] = L(!1), [he, le] = L(""), ce = _(() => {
4696
4696
  const u = he.trim();
4697
4697
  if (!u)
@@ -4711,14 +4711,14 @@ function ed({
4711
4711
  rotationDeg: 45
4712
4712
  };
4713
4713
  });
4714
- C.length > 0 && M(Xn(C)), ne(!1);
4714
+ C.length > 0 && M(jn(C)), ne(!1);
4715
4715
  }, [he, Z, O]), De = j(null), Te = _((u) => {
4716
4716
  M(qt(u)), M(We("signature"));
4717
4717
  }, []), Ze = _(
4718
4718
  (u) => {
4719
4719
  var B;
4720
4720
  const C = (B = u.target.files) == null ? void 0 : B[0];
4721
- u.target.value = "", C && Fn(C).then(Te).catch(
4721
+ u.target.value = "", C && Dn(C).then(Te).catch(
4722
4722
  () => Re(
4723
4723
  m("ds.editors.pdf.signature.upload.error.read-failed")
4724
4724
  )
@@ -4748,7 +4748,7 @@ function ed({
4748
4748
  if (!C)
4749
4749
  return;
4750
4750
  const B = await xr(C.bytes, C.ops, u);
4751
- wn(B, `${Be}-extract.pdf`);
4751
+ mn(B, `${Be}-extract.pdf`);
4752
4752
  } catch (C) {
4753
4753
  fe(C);
4754
4754
  }
@@ -4764,7 +4764,7 @@ function ed({
4764
4764
  await ye(u.bytes, u.ops, e.fileName);
4765
4765
  return;
4766
4766
  }
4767
- const C = await jn(u.bytes, u.ops);
4767
+ const C = await Kn(u.bytes, u.ops);
4768
4768
  await v({
4769
4769
  kind: "DOWNLOAD",
4770
4770
  fileName: e.fileName,
@@ -4814,7 +4814,7 @@ function ed({
4814
4814
  }
4815
4815
  }),
4816
4816
  [ge, Ne, v, fe]
4817
- ), [To, Bt] = L(!1), [Ht, rn] = L(""), [Po, Ut] = L(!1), _n = _(async () => {
4817
+ ), [To, Bt] = L(!1), [Ht, rn] = L(""), [Po, Ut] = L(!1), zn = _(async () => {
4818
4818
  const u = Ht;
4819
4819
  if (!(!(w != null && w.setPassword) || !u)) {
4820
4820
  Bt(!1), rn(""), Ut(!0), Re(null);
@@ -4823,7 +4823,7 @@ function ed({
4823
4823
  if (!C)
4824
4824
  return;
4825
4825
  const B = await w.setPassword(C, u);
4826
- wn(B, `${Be}-protected.pdf`);
4826
+ mn(B, `${Be}-protected.pdf`);
4827
4827
  } catch (C) {
4828
4828
  fe(C);
4829
4829
  } finally {
@@ -4838,7 +4838,7 @@ function ed({
4838
4838
  if (!u)
4839
4839
  return;
4840
4840
  const C = await w.compress(u);
4841
- wn(C, `${Be}.pdf`);
4841
+ mn(C, `${Be}.pdf`);
4842
4842
  const B = u.length - C.length, ue = u.length > 0 ? Math.round(B / u.length * 100) : 0;
4843
4843
  wt(
4844
4844
  B > 0 ? m("ds.editors.pdf.compress.saved", { pct: String(ue) }) : m("ds.editors.pdf.compress.already-optimal")
@@ -4849,10 +4849,10 @@ function ed({
4849
4849
  Ut(!1);
4850
4850
  }
4851
4851
  }
4852
- }, [w, Ne, Be, m, fe]), [Eo, Ct] = L(!1), Oo = _(() => Ct(!0), []), $n = j(y.activeTool);
4852
+ }, [w, Ne, Be, m, fe]), [Eo, Ct] = L(!1), Oo = _(() => Ct(!0), []), _n = j(y.activeTool);
4853
4853
  X(() => {
4854
- const u = $n.current;
4855
- $n.current = y.activeTool, !h && y.activeTool === "signature" && u !== "signature" && y.pendingSignature === null && Ct(!0);
4854
+ const u = _n.current;
4855
+ _n.current = y.activeTool, !h && y.activeTool === "signature" && u !== "signature" && y.pendingSignature === null && Ct(!0);
4856
4856
  }, [y.activeTool, y.pendingSignature, h]);
4857
4857
  const Mo = _(() => {
4858
4858
  Ct(!1), y.activeTool === "signature" && y.pendingSignature === null && M(We("select"));
@@ -4868,13 +4868,13 @@ function ed({
4868
4868
  [d]
4869
4869
  );
4870
4870
  if (R)
4871
- return /* @__PURE__ */ o(jt, { children: /* @__PURE__ */ T(bn, { role: "status", children: [
4871
+ return /* @__PURE__ */ o(jt, { children: /* @__PURE__ */ T(hn, { role: "status", children: [
4872
4872
  /* @__PURE__ */ o(Jt, { "aria-hidden": !0 }),
4873
4873
  /* @__PURE__ */ o("span", { children: m("ds.editors.pdf.loading") })
4874
4874
  ] }) });
4875
4875
  if (W)
4876
- return /* @__PURE__ */ o(jt, { children: /* @__PURE__ */ T(bn, { children: [
4877
- /* @__PURE__ */ o(zs, { children: /* @__PURE__ */ o(St, { severity: Tt.Danger, children: m("ds.editors.pdf.error.load-failed", {
4876
+ return /* @__PURE__ */ o(jt, { children: /* @__PURE__ */ T(hn, { children: [
4877
+ /* @__PURE__ */ o(_s, { children: /* @__PURE__ */ o(St, { severity: Tt.Danger, children: m("ds.editors.pdf.error.load-failed", {
4878
4878
  message: W.message
4879
4879
  }) }) }),
4880
4880
  E && /* @__PURE__ */ o(V, { variant: "outlined", onClick: E, children: m("ds.editors.pdf.error.try-another") })
@@ -4883,10 +4883,10 @@ function ed({
4883
4883
  const u = () => {
4884
4884
  F && ee(F);
4885
4885
  };
4886
- return /* @__PURE__ */ o(jt, { children: /* @__PURE__ */ T(bn, { children: [
4887
- /* @__PURE__ */ o(Fs, { children: m("ds.editors.pdf.unlock.title") }),
4888
- /* @__PURE__ */ o(Ls, { children: m("ds.editors.pdf.unlock.help") }),
4889
- /* @__PURE__ */ o(_s, { children: /* @__PURE__ */ o(
4886
+ return /* @__PURE__ */ o(jt, { children: /* @__PURE__ */ T(hn, { children: [
4887
+ /* @__PURE__ */ o(Ls, { children: m("ds.editors.pdf.unlock.title") }),
4888
+ /* @__PURE__ */ o(zs, { children: m("ds.editors.pdf.unlock.help") }),
4889
+ /* @__PURE__ */ o($s, { children: /* @__PURE__ */ o(
4890
4890
  Vt,
4891
4891
  {
4892
4892
  label: m("ds.editors.pdf.password.label"),
@@ -4907,7 +4907,7 @@ function ed({
4907
4907
  )
4908
4908
  }
4909
4909
  ) }),
4910
- /* @__PURE__ */ T($s, { children: [
4910
+ /* @__PURE__ */ T(Ws, { children: [
4911
4911
  E && /* @__PURE__ */ o(
4912
4912
  V,
4913
4913
  {
@@ -4932,7 +4932,7 @@ function ed({
4932
4932
  }
4933
4933
  if (!z)
4934
4934
  return null;
4935
- const Wn = !!(y.pendingSignature || y.pendingText), Bn = m("ds.editors.pdf.signature.apply-all-pages"), Hn = qe.size === Z.length;
4935
+ const $n = !!(y.pendingSignature || y.pendingText), Wn = m("ds.editors.pdf.signature.apply-all-pages"), Bn = qe.size === Z.length;
4936
4936
  return /* @__PURE__ */ T(jt, { children: [
4937
4937
  !h && /* @__PURE__ */ o(
4938
4938
  Bi,
@@ -4976,10 +4976,10 @@ function ed({
4976
4976
  onSettingsChange: Rt,
4977
4977
  acroFormFields: y.acroFormFields,
4978
4978
  operations: y.operations,
4979
- placementActive: Wn
4979
+ placementActive: $n
4980
4980
  }
4981
4981
  ),
4982
- (Le !== null || bt !== null) && /* @__PURE__ */ T(Ws, { children: [
4982
+ (Le !== null || bt !== null) && /* @__PURE__ */ T(Bs, { children: [
4983
4983
  Le !== null && /* @__PURE__ */ o(
4984
4984
  St,
4985
4985
  {
@@ -4998,7 +4998,7 @@ function ed({
4998
4998
  )
4999
4999
  ] }),
5000
5000
  /* @__PURE__ */ T(
5001
- Bs,
5001
+ Hs,
5002
5002
  {
5003
5003
  ref: xt,
5004
5004
  "data-testid": "pdf-canvas-area",
@@ -5006,14 +5006,14 @@ function ed({
5006
5006
  children: [
5007
5007
  !h && it && /* @__PURE__ */ T(Oe, { children: [
5008
5008
  Ee && /* @__PURE__ */ o(
5009
- Hs,
5009
+ Us,
5010
5010
  {
5011
5011
  "data-testid": "pdf-sidebar-scrim",
5012
5012
  "aria-hidden": !0,
5013
5013
  onClick: () => yt(!1)
5014
5014
  }
5015
5015
  ),
5016
- /* @__PURE__ */ o(Us, { floating: Ee, children: /* @__PURE__ */ o(
5016
+ /* @__PURE__ */ o(Gs, { floating: Ee, children: /* @__PURE__ */ o(
5017
5017
  Is,
5018
5018
  {
5019
5019
  pdfDoc: z,
@@ -5073,15 +5073,15 @@ function ed({
5073
5073
  }
5074
5074
  ),
5075
5075
  !(Ee && it && !h) && /* @__PURE__ */ o(
5076
- Ms,
5076
+ Rs,
5077
5077
  {
5078
5078
  zoom: ze / je,
5079
5079
  onZoomIn: se,
5080
5080
  onZoomOut: Lt,
5081
5081
  onFitWidth: a,
5082
5082
  onResetZoom: Ye,
5083
- canZoomIn: ze < mn - 1e-6,
5084
- canZoomOut: ze > hn + 1e-6,
5083
+ canZoomIn: ze < An - 1e-6,
5084
+ canZoomOut: ze > ro + 1e-6,
5085
5085
  currentPage: vt,
5086
5086
  totalPages: Z.length,
5087
5087
  onGoToPage: x,
@@ -5089,9 +5089,9 @@ function ed({
5089
5089
  sidebarWidth: dt
5090
5090
  }
5091
5091
  ),
5092
- !h && Wn && /* @__PURE__ */ o(Gs, { offset: dt, "data-testid": "pdf-placement", children: /* @__PURE__ */ T(Ks, { children: [
5093
- y.pendingSignature ? /* @__PURE__ */ o(js, { src: y.pendingSignature, alt: "" }) : /* @__PURE__ */ o(Xs, { children: y.pendingText }),
5094
- /* @__PURE__ */ o(Vs, { children: m("ds.editors.pdf.placement.hint") }),
5092
+ !h && $n && /* @__PURE__ */ o(Ks, { offset: dt, "data-testid": "pdf-placement", children: /* @__PURE__ */ T(js, { children: [
5093
+ y.pendingSignature ? /* @__PURE__ */ o(Xs, { src: y.pendingSignature, alt: "" }) : /* @__PURE__ */ o(Vs, { children: y.pendingText }),
5094
+ /* @__PURE__ */ o(Ys, { children: m("ds.editors.pdf.placement.hint") }),
5095
5095
  Z.length > 1 && /* @__PURE__ */ T(Oe, { children: [
5096
5096
  !Ee && /* @__PURE__ */ o(lo, { "aria-hidden": !0 }),
5097
5097
  /* @__PURE__ */ o(
@@ -5099,15 +5099,15 @@ function ed({
5099
5099
  {
5100
5100
  sx: { m: 0 },
5101
5101
  control: /* @__PURE__ */ o(
5102
- Rn,
5102
+ Mn,
5103
5103
  {
5104
5104
  size: "small",
5105
5105
  checked: y.pendingApplyAllPages,
5106
- inputProps: { "aria-label": Bn },
5106
+ inputProps: { "aria-label": Wn },
5107
5107
  onChange: (u, C) => M(At(C))
5108
5108
  }
5109
5109
  ),
5110
- label: Ee ? "" : /* @__PURE__ */ o(Ys, { children: Bn })
5110
+ label: Ee ? "" : /* @__PURE__ */ o(Zs, { children: Wn })
5111
5111
  }
5112
5112
  )
5113
5113
  ] }),
@@ -5118,7 +5118,7 @@ function ed({
5118
5118
  }
5119
5119
  ),
5120
5120
  /* @__PURE__ */ o(
5121
- Zs,
5121
+ qs,
5122
5122
  {
5123
5123
  ref: De,
5124
5124
  type: "file",
@@ -5162,28 +5162,28 @@ function ed({
5162
5162
  }
5163
5163
  )
5164
5164
  ] }),
5165
- children: /* @__PURE__ */ T(qs, { children: [
5166
- /* @__PURE__ */ o(Js, { children: /* @__PURE__ */ o(
5165
+ children: /* @__PURE__ */ T(Js, { children: [
5166
+ /* @__PURE__ */ o(Qs, { children: /* @__PURE__ */ o(
5167
5167
  V,
5168
5168
  {
5169
5169
  variant: "text",
5170
5170
  size: "small",
5171
5171
  onClick: () => lt(
5172
- Hn ? /* @__PURE__ */ new Set() : new Set(Z.map((u, C) => C))
5172
+ Bn ? /* @__PURE__ */ new Set() : new Set(Z.map((u, C) => C))
5173
5173
  ),
5174
5174
  children: m(
5175
- Hn ? "ds.editors.pdf.insert-dialog.select-none" : "ds.editors.pdf.insert-dialog.select-all"
5175
+ Bn ? "ds.editors.pdf.insert-dialog.select-none" : "ds.editors.pdf.insert-dialog.select-all"
5176
5176
  )
5177
5177
  }
5178
5178
  ) }),
5179
- /* @__PURE__ */ o(Qs, { children: Z.map((u, C) => /* @__PURE__ */ o(
5179
+ /* @__PURE__ */ o(ed, { children: Z.map((u, C) => /* @__PURE__ */ o(
5180
5180
  tt,
5181
5181
  {
5182
5182
  label: m("ds.editors.pdf.insert-dialog.page-label", {
5183
5183
  num: C + 1
5184
5184
  }),
5185
5185
  control: /* @__PURE__ */ o(
5186
- Mn,
5186
+ On,
5187
5187
  {
5188
5188
  checked: qe.has(C),
5189
5189
  onChange: (B) => lt((ue) => {
@@ -5213,7 +5213,7 @@ function ed({
5213
5213
  {
5214
5214
  variant: "contained",
5215
5215
  disabled: !Ht,
5216
- onClick: () => void _n(),
5216
+ onClick: () => void zn(),
5217
5217
  children: m("ds.editors.pdf.password.confirm")
5218
5218
  }
5219
5219
  )
@@ -5227,7 +5227,7 @@ function ed({
5227
5227
  value: Ht,
5228
5228
  onChange: (u) => rn(u.target.value),
5229
5229
  onKeyDown: (u) => {
5230
- u.key === "Enter" && _n();
5230
+ u.key === "Enter" && zn();
5231
5231
  }
5232
5232
  }
5233
5233
  ) })
@@ -5268,7 +5268,7 @@ function ed({
5268
5268
  ] });
5269
5269
  }
5270
5270
  export {
5271
- yl as MarkdownEditor,
5272
- xl as PdfEditor,
5271
+ xl as MarkdownEditor,
5272
+ kl as PdfEditor,
5273
5273
  H as PdfOperationType
5274
5274
  };