@stll/folio-react 0.25.2 → 0.26.0

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 (26) hide show
  1. package/README.md +1 -1
  2. package/dist/{CommentsSidebar-IR9uTkkk.js → CommentsSidebar-C4IpXib8.js} +53 -33
  3. package/dist/{FindReplaceDialog-BUwFQWaq.js → FindReplaceDialog-LlVMe3EW.js} +148 -107
  4. package/dist/{FootnotePropertiesDialog-6XdO0zBH.js → FootnotePropertiesDialog-D73t3LNP.js} +1 -1
  5. package/dist/ImagePositionDialog-Cwt6R8iM.js +1039 -0
  6. package/dist/ImagePropertiesDialog-GNZLBFLB.js +607 -0
  7. package/dist/{InsertSymbolDialog-Cn_Nifhg.js → InsertSymbolDialog-CeEhkEvc.js} +1 -1
  8. package/dist/PageSetupDialog-DD6IEZAo.js +805 -0
  9. package/dist/SetNumberingValueDialog-CDQGDvP1.js +233 -0
  10. package/dist/TablePropertiesDialog-Vu0HXQz6.js +416 -0
  11. package/dist/{TextContextMenu-Bqth8itn.js → TextContextMenu-DZ3AUFKh.js} +4 -2
  12. package/dist/compat/eigenpal.js +1 -1
  13. package/dist/{dialogs-DZz6gVev.d.ts → dialogs-BENP66Ly.d.ts} +11 -11
  14. package/dist/{dialogs-Dzu4hqRp.js → dialogs-De-oslzU.js} +417 -394
  15. package/dist/dialogs.d.ts +1 -1
  16. package/dist/dialogs.js +8 -8
  17. package/dist/{folio-ui-DO95voaI.js → folio-ui-rCHqCEG6.js} +125 -35
  18. package/dist/index.d.ts +1 -1
  19. package/dist/index.js +10 -10
  20. package/dist/{renderAsync-C0_y_c9Y.js → renderAsync-T2p_qqNU.js} +2843 -2022
  21. package/package.json +4 -4
  22. package/dist/ImagePositionDialog-9q71ka9N.js +0 -1065
  23. package/dist/ImagePropertiesDialog-o79NCGk7.js +0 -613
  24. package/dist/PageSetupDialog-CMdVXCZ-.js +0 -820
  25. package/dist/SetNumberingValueDialog-DOsaSq7e.js +0 -237
  26. package/dist/TablePropertiesDialog-DwPiUj4m.js +0 -421
@@ -1,44 +1,41 @@
1
- import { r as useFolioUI } from "./folio-ui-DO95voaI.js";
1
+ import { r as useFolioUI } from "./folio-ui-rCHqCEG6.js";
2
2
  import { a as DIALOG_LABEL_CLASS, c as DIALOG_SECONDARY_BUTTON_CLASS, i as DIALOG_INPUT_CLASS, l as DIALOG_TITLE_CLASS, n as DIALOG_BODY_CLASS, o as DIALOG_POPUP_CLASS, r as DIALOG_FOOTER_CLASS, s as DIALOG_PRIMARY_BUTTON_CLASS, t as DIALOG_BACKDROP_CLASS, u as useCloseOnDialogOpenChange } from "./dialogChrome-BoGYPgeu.js";
3
3
  import { c } from "react-compiler-runtime";
4
- import { useEffect, useId, useState } from "react";
4
+ import { useId, useState } from "react";
5
5
  import { useTranslations } from "use-intl";
6
6
  import { jsx, jsxs } from "react/jsx-runtime";
7
7
  import { isAllowedExternalWatermarkImageUrl } from "@stll/folio-core/watermark";
8
8
  //#region src/components/dialogs/HyperlinkDialog.tsx
9
- function HyperlinkDialog({ isOpen, onClose, onSubmit, onRemove, currentData, selectedText, bookmarks = [] }) {
9
+ function HyperlinkDialog(props) {
10
+ const $ = c(6);
11
+ if (!props.isOpen) return null;
12
+ let t0;
13
+ if ($[0] !== props.currentData || $[1] !== props.selectedText) {
14
+ t0 = JSON.stringify([props.currentData, props.selectedText]);
15
+ $[0] = props.currentData;
16
+ $[1] = props.selectedText;
17
+ $[2] = t0;
18
+ } else t0 = $[2];
19
+ let t1;
20
+ if ($[3] !== props || $[4] !== t0) {
21
+ t1 = /* @__PURE__ */ jsx(HyperlinkDialogForm, { ...props }, t0);
22
+ $[3] = props;
23
+ $[4] = t0;
24
+ $[5] = t1;
25
+ } else t1 = $[5];
26
+ return t1;
27
+ }
28
+ function HyperlinkDialogForm({ isOpen, onClose, onSubmit, onRemove, currentData, selectedText, bookmarks = [] }) {
10
29
  const { Root: Dialog, Portal: DialogPortal, Backdrop: DialogBackdrop, Popup: DialogPopup, Title: DialogTitle, Close: DialogClose } = useFolioUI().Dialog;
11
30
  const handleOpenChange = useCloseOnDialogOpenChange(onClose);
12
31
  const t = useTranslations("folio");
13
32
  const id = useId();
14
- const [targetType, setTargetType] = useState("url");
15
- const [url, setUrl] = useState("");
16
- const [bookmark, setBookmark] = useState("");
17
- const [displayText, setDisplayText] = useState("");
18
- const [tooltip, setTooltip] = useState("");
33
+ const [targetType, setTargetType] = useState(currentData?.href?.startsWith("#") ? "bookmark" : "url");
34
+ const [url, setUrl] = useState(currentData?.href?.startsWith("#") ? "" : currentData?.href ?? "");
35
+ const [bookmark, setBookmark] = useState(currentData?.href?.startsWith("#") ? currentData.href.slice(1) : "");
36
+ const [displayText, setDisplayText] = useState(currentData?.displayText ?? selectedText ?? "");
37
+ const [tooltip, setTooltip] = useState(currentData?.tooltip ?? "");
19
38
  const [touched, setTouched] = useState(false);
20
- useEffect(() => {
21
- if (!isOpen) {
22
- setTouched(false);
23
- return;
24
- }
25
- const href = currentData?.href ?? "";
26
- if (href.startsWith("#")) {
27
- setTargetType("bookmark");
28
- setBookmark(href.slice(1));
29
- setUrl("");
30
- } else {
31
- setTargetType("url");
32
- setUrl(href);
33
- setBookmark("");
34
- }
35
- setDisplayText(currentData?.displayText ?? selectedText ?? "");
36
- setTooltip(currentData?.tooltip ?? "");
37
- }, [
38
- isOpen,
39
- currentData,
40
- selectedText
41
- ]);
42
39
  const urlError = targetType === "url" ? getUrlError(url) : "";
43
40
  const canSubmit = targetType === "bookmark" ? bookmark.trim().length > 0 : url.trim().length > 0 && urlError.length === 0;
44
41
  const isEditing = Boolean(currentData?.href);
@@ -52,10 +49,10 @@ function HyperlinkDialog({ isOpen, onClose, onSubmit, onRemove, currentData, sel
52
49
  const handleSubmit = () => {
53
50
  setTouched(true);
54
51
  if (!canSubmit) return;
55
- const href_0 = targetType === "bookmark" ? `#${bookmark.trim()}` : normalizeUrl(url);
52
+ const href = targetType === "bookmark" ? `#${bookmark.trim()}` : normalizeUrl(url);
56
53
  onSubmit({
57
- href: href_0,
58
- displayText: displayText.trim() || href_0,
54
+ href,
55
+ displayText: displayText.trim() || href,
59
56
  ...tooltip.trim() ? { tooltip: tooltip.trim() } : {}
60
57
  });
61
58
  onClose();
@@ -216,7 +213,18 @@ function normalizeUrl(value) {
216
213
  }
217
214
  //#endregion
218
215
  //#region src/components/dialogs/InsertImageDialog.tsx
219
- function InsertImageDialog({ isOpen, onClose, onInsert, accept = "image/png,image/jpeg,image/gif,image/webp" }) {
216
+ function InsertImageDialog(props) {
217
+ const $ = c(2);
218
+ if (!props.isOpen) return null;
219
+ let t0;
220
+ if ($[0] !== props) {
221
+ t0 = /* @__PURE__ */ jsx(InsertImageDialogForm, { ...props });
222
+ $[0] = props;
223
+ $[1] = t0;
224
+ } else t0 = $[1];
225
+ return t0;
226
+ }
227
+ function InsertImageDialogForm({ isOpen, onClose, onInsert, accept = "image/png,image/jpeg,image/gif,image/webp" }) {
220
228
  const { Root: Dialog, Portal: DialogPortal, Backdrop: DialogBackdrop, Popup: DialogPopup, Title: DialogTitle, Close: DialogClose } = useFolioUI().Dialog;
221
229
  const handleOpenChange = useCloseOnDialogOpenChange(onClose);
222
230
  const t = useTranslations("folio");
@@ -225,13 +233,6 @@ function InsertImageDialog({ isOpen, onClose, onInsert, accept = "image/png,imag
225
233
  const [alt, setAlt] = useState("");
226
234
  const [width, setWidth] = useState("");
227
235
  const [height, setHeight] = useState("");
228
- useEffect(() => {
229
- if (!isOpen) return;
230
- setFile(null);
231
- setAlt("");
232
- setWidth("");
233
- setHeight("");
234
- }, [isOpen]);
235
236
  const fieldIds = {
236
237
  file: `${id}-insert-image-file`,
237
238
  alt: `${id}-insert-image-alt`,
@@ -370,7 +371,26 @@ const DEFAULT_STYLE_OPTIONS = [
370
371
  name: "Grid Table Light"
371
372
  }
372
373
  ];
373
- function InsertTableDialog({ isOpen, onClose, onInsert, defaultRows = 3, defaultColumns = 3, styleOptions = DEFAULT_STYLE_OPTIONS }) {
374
+ function InsertTableDialog(props) {
375
+ const $ = c(6);
376
+ if (!props.isOpen) return null;
377
+ let t0;
378
+ if ($[0] !== props.defaultColumns || $[1] !== props.defaultRows) {
379
+ t0 = JSON.stringify([props.defaultRows, props.defaultColumns]);
380
+ $[0] = props.defaultColumns;
381
+ $[1] = props.defaultRows;
382
+ $[2] = t0;
383
+ } else t0 = $[2];
384
+ let t1;
385
+ if ($[3] !== props || $[4] !== t0) {
386
+ t1 = /* @__PURE__ */ jsx(InsertTableDialogForm, { ...props }, t0);
387
+ $[3] = props;
388
+ $[4] = t0;
389
+ $[5] = t1;
390
+ } else t1 = $[5];
391
+ return t1;
392
+ }
393
+ function InsertTableDialogForm({ isOpen, onClose, onInsert, defaultRows = 3, defaultColumns = 3, styleOptions = DEFAULT_STYLE_OPTIONS }) {
374
394
  const { Root: Dialog, Portal: DialogPortal, Backdrop: DialogBackdrop, Popup: DialogPopup, Title: DialogTitle, Close: DialogClose } = useFolioUI().Dialog;
375
395
  const handleOpenChange = useCloseOnDialogOpenChange(onClose);
376
396
  const t = useTranslations("folio");
@@ -381,19 +401,6 @@ function InsertTableDialog({ isOpen, onClose, onInsert, defaultRows = 3, default
381
401
  const [hoverColumns, setHoverColumns] = useState(0);
382
402
  const [autofit, setAutofit] = useState(false);
383
403
  const [styleId, setStyleId] = useState("");
384
- useEffect(() => {
385
- if (!isOpen) return;
386
- setRows(defaultRows);
387
- setColumns(defaultColumns);
388
- setHoverRows(0);
389
- setHoverColumns(0);
390
- setAutofit(false);
391
- setStyleId("");
392
- }, [
393
- isOpen,
394
- defaultRows,
395
- defaultColumns
396
- ]);
397
404
  const normalizedRows = clampInteger$1(rows, MIN_ROWS, MAX_ROWS);
398
405
  const normalizedColumns = clampInteger$1(columns, MIN_COLUMNS, MAX_COLUMNS);
399
406
  const canInsert = Number.isFinite(rows) && Number.isFinite(columns);
@@ -563,15 +570,30 @@ const PASTE_MODES = [
563
570
  description: "Paste text only and use the destination formatting."
564
571
  }
565
572
  ];
566
- function PasteSpecialDialog({ isOpen, onClose, onPaste, defaultMode = "plainText" }) {
573
+ function PasteSpecialDialog(props) {
574
+ const $ = c(5);
575
+ if (!props.isOpen) return null;
576
+ let t0;
577
+ if ($[0] !== props.defaultMode) {
578
+ t0 = JSON.stringify(props.defaultMode);
579
+ $[0] = props.defaultMode;
580
+ $[1] = t0;
581
+ } else t0 = $[1];
582
+ let t1;
583
+ if ($[2] !== props || $[3] !== t0) {
584
+ t1 = /* @__PURE__ */ jsx(PasteSpecialDialogForm, { ...props }, t0);
585
+ $[2] = props;
586
+ $[3] = t0;
587
+ $[4] = t1;
588
+ } else t1 = $[4];
589
+ return t1;
590
+ }
591
+ function PasteSpecialDialogForm({ isOpen, onClose, onPaste, defaultMode = "plainText" }) {
567
592
  const { Root: Dialog, Portal: DialogPortal, Backdrop: DialogBackdrop, Popup: DialogPopup, Title: DialogTitle, Close: DialogClose } = useFolioUI().Dialog;
568
593
  const handleOpenChange = useCloseOnDialogOpenChange(onClose);
569
594
  const t = useTranslations("folio");
570
595
  const id = useId();
571
596
  const [mode, setMode] = useState(defaultMode);
572
- useEffect(() => {
573
- if (isOpen) setMode(defaultMode);
574
- }, [isOpen, defaultMode]);
575
597
  const handlePaste = () => {
576
598
  onPaste(mode);
577
599
  onClose();
@@ -637,7 +659,26 @@ function PasteSpecialDialog({ isOpen, onClose, onPaste, defaultMode = "plainText
637
659
  //#region src/components/dialogs/SplitCellDialog.tsx
638
660
  const MIN_PARTS = 1;
639
661
  const MAX_PARTS = 63;
640
- function SplitCellDialog({ isOpen, onClose, onSplit, defaultRows = 1, defaultColumns = 2 }) {
662
+ function SplitCellDialog(props) {
663
+ const $ = c(6);
664
+ if (!props.isOpen) return null;
665
+ let t0;
666
+ if ($[0] !== props.defaultColumns || $[1] !== props.defaultRows) {
667
+ t0 = JSON.stringify([props.defaultRows, props.defaultColumns]);
668
+ $[0] = props.defaultColumns;
669
+ $[1] = props.defaultRows;
670
+ $[2] = t0;
671
+ } else t0 = $[2];
672
+ let t1;
673
+ if ($[3] !== props || $[4] !== t0) {
674
+ t1 = /* @__PURE__ */ jsx(SplitCellDialogForm, { ...props }, t0);
675
+ $[3] = props;
676
+ $[4] = t0;
677
+ $[5] = t1;
678
+ } else t1 = $[5];
679
+ return t1;
680
+ }
681
+ function SplitCellDialogForm({ isOpen, onClose, onSplit, defaultRows = 1, defaultColumns = 2 }) {
641
682
  const { Root: Dialog, Portal: DialogPortal, Backdrop: DialogBackdrop, Popup: DialogPopup, Title: DialogTitle, Close: DialogClose } = useFolioUI().Dialog;
642
683
  const handleOpenChange = useCloseOnDialogOpenChange(onClose);
643
684
  const t = useTranslations("folio");
@@ -645,16 +686,6 @@ function SplitCellDialog({ isOpen, onClose, onSplit, defaultRows = 1, defaultCol
645
686
  const [rows, setRows] = useState(defaultRows);
646
687
  const [columns, setColumns] = useState(defaultColumns);
647
688
  const [mergeBeforeSplit, setMergeBeforeSplit] = useState(false);
648
- useEffect(() => {
649
- if (!isOpen) return;
650
- setRows(defaultRows);
651
- setColumns(defaultColumns);
652
- setMergeBeforeSplit(false);
653
- }, [
654
- isOpen,
655
- defaultRows,
656
- defaultColumns
657
- ]);
658
689
  const normalizedRows = clampInteger(rows);
659
690
  const normalizedColumns = clampInteger(columns);
660
691
  const canSplit = normalizedRows > 1 || normalizedColumns > 1;
@@ -754,130 +785,122 @@ function clampInteger(value) {
754
785
  //#endregion
755
786
  //#region src/components/dialogs/WatermarkDialog.tsx
756
787
  const DEFAULT_TEXT_COLOR = "#C0C0C0";
757
- function WatermarkDialog(t0) {
758
- const $ = c(133);
788
+ function WatermarkDialog(props) {
789
+ const $ = c(5);
790
+ if (!props.isOpen) return null;
791
+ let t0;
792
+ if ($[0] !== props.currentWatermark) {
793
+ t0 = JSON.stringify(props.currentWatermark);
794
+ $[0] = props.currentWatermark;
795
+ $[1] = t0;
796
+ } else t0 = $[1];
797
+ let t1;
798
+ if ($[2] !== props || $[3] !== t0) {
799
+ t1 = /* @__PURE__ */ jsx(WatermarkDialogForm, { ...props }, t0);
800
+ $[2] = props;
801
+ $[3] = t0;
802
+ $[4] = t1;
803
+ } else t1 = $[4];
804
+ return t1;
805
+ }
806
+ function WatermarkDialogForm(t0) {
807
+ const $ = c(135);
759
808
  const { isOpen, onClose, onApply, currentWatermark } = t0;
760
809
  const { Root: Dialog, Portal: DialogPortal, Backdrop: DialogBackdrop, Popup: DialogPopup, Title: DialogTitle, Close: DialogClose } = useFolioUI().Dialog;
761
810
  const handleOpenChange = useCloseOnDialogOpenChange(onClose);
762
811
  const t = useTranslations("folio");
763
812
  const id = useId();
764
- const [mode, setMode] = useState("text");
765
- const [text, setText] = useState("CONFIDENTIAL");
766
- const [font, setFont] = useState("Calibri");
767
- const [color, setColor] = useState(DEFAULT_TEXT_COLOR);
768
- const [diagonal, setDiagonal] = useState(true);
769
- const [opacityPercent, setOpacityPercent] = useState(50);
770
- const [imageRId, setImageRId] = useState("");
771
- const [imageTarget, setImageTarget] = useState("");
772
- const [imageTargetExternal, setImageTargetExternal] = useState(false);
773
- const [scalePercent, setScalePercent] = useState(100);
774
- const [washout, setWashout] = useState(true);
813
+ const [mode, setMode] = useState(currentWatermark?.kind ?? "text");
814
+ const [text, setText] = useState(currentWatermark?.kind === "text" ? currentWatermark.text : "CONFIDENTIAL");
815
+ const [font, setFont] = useState(currentWatermark?.kind === "text" ? currentWatermark.font ?? "Calibri" : "Calibri");
775
816
  let t1;
776
- let t2;
777
- if ($[0] !== currentWatermark || $[1] !== isOpen) {
778
- t1 = () => {
779
- if (!isOpen) return;
780
- if (!currentWatermark) {
781
- setMode("text");
782
- setText("CONFIDENTIAL");
783
- setFont("Calibri");
784
- setColor(DEFAULT_TEXT_COLOR);
785
- setDiagonal(true);
786
- setOpacityPercent(50);
787
- setImageRId("");
788
- setImageTarget("");
789
- setImageTargetExternal(false);
790
- setScalePercent(100);
791
- setWashout(true);
792
- return;
793
- }
794
- setMode(currentWatermark.kind);
795
- if (currentWatermark.kind === "text") {
796
- setText(currentWatermark.text);
797
- setFont(currentWatermark.font ?? "Calibri");
798
- setColor(toColorInputValue(currentWatermark.color));
799
- setDiagonal(currentWatermark.diagonal ?? true);
800
- setOpacityPercent(Math.round((currentWatermark.opacity ?? .5) * 100));
801
- return;
802
- }
803
- setImageRId(currentWatermark.imageRId);
804
- setImageTarget(currentWatermark.imageTarget ?? "");
805
- setImageTargetExternal(currentWatermark.imageTargetExternal ?? false);
806
- setScalePercent(Math.round((currentWatermark.scale ?? 1) * 100));
807
- setWashout(currentWatermark.washout ?? true);
808
- };
809
- t2 = [isOpen, currentWatermark];
817
+ if ($[0] !== currentWatermark) {
818
+ t1 = currentWatermark?.kind === "text" ? toColorInputValue(currentWatermark.color) : DEFAULT_TEXT_COLOR;
810
819
  $[0] = currentWatermark;
811
- $[1] = isOpen;
812
- $[2] = t1;
820
+ $[1] = t1;
821
+ } else t1 = $[1];
822
+ const [color, setColor] = useState(t1);
823
+ const [diagonal, setDiagonal] = useState(currentWatermark?.kind === "text" ? currentWatermark.diagonal ?? true : true);
824
+ let t2;
825
+ if ($[2] !== currentWatermark) {
826
+ t2 = currentWatermark?.kind === "text" ? Math.round((currentWatermark.opacity ?? .5) * 100) : 50;
827
+ $[2] = currentWatermark;
813
828
  $[3] = t2;
814
- } else {
815
- t1 = $[2];
816
- t2 = $[3];
817
- }
818
- useEffect(t1, t2);
819
- const t3 = `${id}-watermark-mode`;
820
- const t4 = `${id}-watermark-text`;
821
- const t5 = `${id}-watermark-font`;
822
- const t6 = `${id}-watermark-color`;
823
- const t7 = `${id}-watermark-diagonal`;
824
- const t8 = `${id}-watermark-opacity`;
825
- const t9 = `${id}-watermark-image-rid`;
826
- const t10 = `${id}-watermark-image-target`;
827
- const t11 = `${id}-watermark-image-external`;
828
- const t12 = `${id}-watermark-scale`;
829
- const t13 = `${id}-watermark-washout`;
830
- let t14;
831
- if ($[4] !== t10 || $[5] !== t11 || $[6] !== t12 || $[7] !== t13 || $[8] !== t3 || $[9] !== t4 || $[10] !== t5 || $[11] !== t6 || $[12] !== t7 || $[13] !== t8 || $[14] !== t9) {
832
- t14 = {
833
- mode: t3,
834
- text: t4,
835
- font: t5,
836
- color: t6,
837
- diagonal: t7,
838
- opacity: t8,
839
- imageRId: t9,
840
- imageTarget: t10,
841
- imageTargetExternal: t11,
842
- scale: t12,
843
- washout: t13
844
- };
845
- $[4] = t10;
846
- $[5] = t11;
847
- $[6] = t12;
848
- $[7] = t13;
849
- $[8] = t3;
850
- $[9] = t4;
851
- $[10] = t5;
852
- $[11] = t6;
853
- $[12] = t7;
854
- $[13] = t8;
855
- $[14] = t9;
856
- $[15] = t14;
857
- } else t14 = $[15];
858
- const fieldIds = t14;
829
+ } else t2 = $[3];
830
+ const [opacityPercent, setOpacityPercent] = useState(t2);
831
+ const [imageRId, setImageRId] = useState(currentWatermark?.kind === "picture" ? currentWatermark.imageRId ?? "" : "");
832
+ const [imageTarget, setImageTarget] = useState(currentWatermark?.kind === "picture" ? currentWatermark.imageTarget ?? "" : "");
833
+ const [imageTargetExternal, setImageTargetExternal] = useState(currentWatermark?.kind === "picture" ? currentWatermark.imageTargetExternal ?? false : false);
834
+ let t3;
835
+ if ($[4] !== currentWatermark) {
836
+ t3 = currentWatermark?.kind === "picture" ? Math.round((currentWatermark.scale ?? 1) * 100) : 100;
837
+ $[4] = currentWatermark;
838
+ $[5] = t3;
839
+ } else t3 = $[5];
840
+ const [scalePercent, setScalePercent] = useState(t3);
841
+ const [washout, setWashout] = useState(currentWatermark?.kind === "picture" ? currentWatermark.washout ?? true : true);
842
+ const t4 = `${id}-watermark-mode`;
843
+ const t5 = `${id}-watermark-text`;
844
+ const t6 = `${id}-watermark-font`;
845
+ const t7 = `${id}-watermark-color`;
846
+ const t8 = `${id}-watermark-diagonal`;
847
+ const t9 = `${id}-watermark-opacity`;
848
+ const t10 = `${id}-watermark-image-rid`;
849
+ const t11 = `${id}-watermark-image-target`;
850
+ const t12 = `${id}-watermark-image-external`;
851
+ const t13 = `${id}-watermark-scale`;
852
+ const t14 = `${id}-watermark-washout`;
859
853
  let t15;
860
- if ($[16] !== imageTarget || $[17] !== imageTargetExternal || $[18] !== mode) {
861
- t15 = mode === "picture" && imageTargetExternal && imageTarget.trim().length > 0 ? getExternalImageTargetError(imageTarget.trim()) : "";
862
- $[16] = imageTarget;
863
- $[17] = imageTargetExternal;
864
- $[18] = mode;
865
- $[19] = t15;
866
- } else t15 = $[19];
867
- const imageTargetError = t15;
854
+ if ($[6] !== t10 || $[7] !== t11 || $[8] !== t12 || $[9] !== t13 || $[10] !== t14 || $[11] !== t4 || $[12] !== t5 || $[13] !== t6 || $[14] !== t7 || $[15] !== t8 || $[16] !== t9) {
855
+ t15 = {
856
+ mode: t4,
857
+ text: t5,
858
+ font: t6,
859
+ color: t7,
860
+ diagonal: t8,
861
+ opacity: t9,
862
+ imageRId: t10,
863
+ imageTarget: t11,
864
+ imageTargetExternal: t12,
865
+ scale: t13,
866
+ washout: t14
867
+ };
868
+ $[6] = t10;
869
+ $[7] = t11;
870
+ $[8] = t12;
871
+ $[9] = t13;
872
+ $[10] = t14;
873
+ $[11] = t4;
874
+ $[12] = t5;
875
+ $[13] = t6;
876
+ $[14] = t7;
877
+ $[15] = t8;
878
+ $[16] = t9;
879
+ $[17] = t15;
880
+ } else t15 = $[17];
881
+ const fieldIds = t15;
868
882
  let t16;
869
- if ($[20] !== imageRId || $[21] !== imageTargetError || $[22] !== mode || $[23] !== text) {
870
- t16 = mode === "none" || mode === "text" && text.trim().length > 0 || mode === "picture" && imageRId.trim().length > 0 && imageTargetError.length === 0;
871
- $[20] = imageRId;
872
- $[21] = imageTargetError;
873
- $[22] = mode;
874
- $[23] = text;
875
- $[24] = t16;
876
- } else t16 = $[24];
877
- const canApply = t16;
883
+ if ($[18] !== imageTarget || $[19] !== imageTargetExternal || $[20] !== mode) {
884
+ t16 = mode === "picture" && imageTargetExternal && imageTarget.trim().length > 0 ? getExternalImageTargetError(imageTarget.trim()) : "";
885
+ $[18] = imageTarget;
886
+ $[19] = imageTargetExternal;
887
+ $[20] = mode;
888
+ $[21] = t16;
889
+ } else t16 = $[21];
890
+ const imageTargetError = t16;
878
891
  let t17;
879
- if ($[25] !== canApply || $[26] !== color || $[27] !== diagonal || $[28] !== font || $[29] !== imageRId || $[30] !== imageTarget || $[31] !== imageTargetExternal || $[32] !== mode || $[33] !== onApply || $[34] !== onClose || $[35] !== opacityPercent || $[36] !== scalePercent || $[37] !== text || $[38] !== washout) {
880
- t17 = () => {
892
+ if ($[22] !== imageRId || $[23] !== imageTargetError || $[24] !== mode || $[25] !== text) {
893
+ t17 = mode === "none" || mode === "text" && text.trim().length > 0 || mode === "picture" && imageRId.trim().length > 0 && imageTargetError.length === 0;
894
+ $[22] = imageRId;
895
+ $[23] = imageTargetError;
896
+ $[24] = mode;
897
+ $[25] = text;
898
+ $[26] = t17;
899
+ } else t17 = $[26];
900
+ const canApply = t17;
901
+ let t18;
902
+ if ($[27] !== canApply || $[28] !== color || $[29] !== diagonal || $[30] !== font || $[31] !== imageRId || $[32] !== imageTarget || $[33] !== imageTargetExternal || $[34] !== mode || $[35] !== onApply || $[36] !== onClose || $[37] !== opacityPercent || $[38] !== scalePercent || $[39] !== text || $[40] !== washout) {
903
+ t18 = () => {
881
904
  if (!canApply) return;
882
905
  if (mode === "none") {
883
906
  onApply(void 0);
@@ -906,147 +929,147 @@ function WatermarkDialog(t0) {
906
929
  });
907
930
  onClose();
908
931
  };
909
- $[25] = canApply;
910
- $[26] = color;
911
- $[27] = diagonal;
912
- $[28] = font;
913
- $[29] = imageRId;
914
- $[30] = imageTarget;
915
- $[31] = imageTargetExternal;
916
- $[32] = mode;
917
- $[33] = onApply;
918
- $[34] = onClose;
919
- $[35] = opacityPercent;
920
- $[36] = scalePercent;
921
- $[37] = text;
922
- $[38] = washout;
923
- $[39] = t17;
924
- } else t17 = $[39];
925
- const handleApply = t17;
926
- let t18;
927
- if ($[40] !== DialogBackdrop) {
928
- t18 = /* @__PURE__ */ jsx(DialogBackdrop, { className: DIALOG_BACKDROP_CLASS });
929
- $[40] = DialogBackdrop;
932
+ $[27] = canApply;
933
+ $[28] = color;
934
+ $[29] = diagonal;
935
+ $[30] = font;
936
+ $[31] = imageRId;
937
+ $[32] = imageTarget;
938
+ $[33] = imageTargetExternal;
939
+ $[34] = mode;
940
+ $[35] = onApply;
941
+ $[36] = onClose;
942
+ $[37] = opacityPercent;
943
+ $[38] = scalePercent;
944
+ $[39] = text;
945
+ $[40] = washout;
930
946
  $[41] = t18;
931
947
  } else t18 = $[41];
948
+ const handleApply = t18;
932
949
  let t19;
933
- if ($[42] !== t) {
934
- t19 = t("dialogs.watermark.title");
935
- $[42] = t;
950
+ if ($[42] !== DialogBackdrop) {
951
+ t19 = /* @__PURE__ */ jsx(DialogBackdrop, { className: DIALOG_BACKDROP_CLASS });
952
+ $[42] = DialogBackdrop;
936
953
  $[43] = t19;
937
954
  } else t19 = $[43];
938
955
  let t20;
939
- if ($[44] !== DialogTitle || $[45] !== t19) {
940
- t20 = /* @__PURE__ */ jsx(DialogTitle, {
956
+ if ($[44] !== t) {
957
+ t20 = t("dialogs.watermark.title");
958
+ $[44] = t;
959
+ $[45] = t20;
960
+ } else t20 = $[45];
961
+ let t21;
962
+ if ($[46] !== DialogTitle || $[47] !== t20) {
963
+ t21 = /* @__PURE__ */ jsx(DialogTitle, {
941
964
  className: DIALOG_TITLE_CLASS,
942
- children: t19
965
+ children: t20
943
966
  });
944
- $[44] = DialogTitle;
945
- $[45] = t19;
946
- $[46] = t20;
947
- } else t20 = $[46];
948
- const t21 = fieldIds.mode;
949
- let t22;
950
- if ($[47] !== t) {
951
- t22 = t("dialogs.watermark.type");
952
- $[47] = t;
953
- $[48] = t22;
954
- } else t22 = $[48];
967
+ $[46] = DialogTitle;
968
+ $[47] = t20;
969
+ $[48] = t21;
970
+ } else t21 = $[48];
971
+ const t22 = fieldIds.mode;
955
972
  let t23;
956
- if ($[49] !== t22) {
957
- t23 = /* @__PURE__ */ jsx("span", {
958
- className: DIALOG_LABEL_CLASS,
959
- children: t22
960
- });
961
- $[49] = t22;
973
+ if ($[49] !== t) {
974
+ t23 = t("dialogs.watermark.type");
975
+ $[49] = t;
962
976
  $[50] = t23;
963
977
  } else t23 = $[50];
964
- const t24 = fieldIds.mode;
965
- let t25;
966
- if ($[51] === Symbol.for("react.memo_cache_sentinel")) {
967
- t25 = (e) => setMode(toWatermarkMode(e.target.value));
968
- $[51] = t25;
969
- } else t25 = $[51];
978
+ let t24;
979
+ if ($[51] !== t23) {
980
+ t24 = /* @__PURE__ */ jsx("span", {
981
+ className: DIALOG_LABEL_CLASS,
982
+ children: t23
983
+ });
984
+ $[51] = t23;
985
+ $[52] = t24;
986
+ } else t24 = $[52];
987
+ const t25 = fieldIds.mode;
970
988
  let t26;
971
- if ($[52] !== t) {
972
- t26 = t("dialogs.watermark.textWatermark");
973
- $[52] = t;
989
+ if ($[53] === Symbol.for("react.memo_cache_sentinel")) {
990
+ t26 = (e) => setMode(toWatermarkMode(e.target.value));
974
991
  $[53] = t26;
975
992
  } else t26 = $[53];
976
993
  let t27;
977
- if ($[54] !== t26) {
978
- t27 = /* @__PURE__ */ jsx("option", {
979
- value: "text",
980
- children: t26
981
- });
982
- $[54] = t26;
994
+ if ($[54] !== t) {
995
+ t27 = t("dialogs.watermark.textWatermark");
996
+ $[54] = t;
983
997
  $[55] = t27;
984
998
  } else t27 = $[55];
985
999
  let t28;
986
- if ($[56] !== t) {
987
- t28 = t("dialogs.watermark.pictureWatermark");
988
- $[56] = t;
1000
+ if ($[56] !== t27) {
1001
+ t28 = /* @__PURE__ */ jsx("option", {
1002
+ value: "text",
1003
+ children: t27
1004
+ });
1005
+ $[56] = t27;
989
1006
  $[57] = t28;
990
1007
  } else t28 = $[57];
991
1008
  let t29;
992
- if ($[58] !== t28) {
993
- t29 = /* @__PURE__ */ jsx("option", {
994
- value: "picture",
995
- children: t28
996
- });
997
- $[58] = t28;
1009
+ if ($[58] !== t) {
1010
+ t29 = t("dialogs.watermark.pictureWatermark");
1011
+ $[58] = t;
998
1012
  $[59] = t29;
999
1013
  } else t29 = $[59];
1000
1014
  let t30;
1001
- if ($[60] !== t) {
1002
- t30 = t("dialogs.watermark.noWatermark");
1003
- $[60] = t;
1015
+ if ($[60] !== t29) {
1016
+ t30 = /* @__PURE__ */ jsx("option", {
1017
+ value: "picture",
1018
+ children: t29
1019
+ });
1020
+ $[60] = t29;
1004
1021
  $[61] = t30;
1005
1022
  } else t30 = $[61];
1006
1023
  let t31;
1007
- if ($[62] !== t30) {
1008
- t31 = /* @__PURE__ */ jsx("option", {
1009
- value: "none",
1010
- children: t30
1011
- });
1012
- $[62] = t30;
1024
+ if ($[62] !== t) {
1025
+ t31 = t("dialogs.watermark.noWatermark");
1026
+ $[62] = t;
1013
1027
  $[63] = t31;
1014
1028
  } else t31 = $[63];
1015
1029
  let t32;
1016
- if ($[64] !== fieldIds.mode || $[65] !== mode || $[66] !== t27 || $[67] !== t29 || $[68] !== t31) {
1017
- t32 = /* @__PURE__ */ jsxs("select", {
1030
+ if ($[64] !== t31) {
1031
+ t32 = /* @__PURE__ */ jsx("option", {
1032
+ value: "none",
1033
+ children: t31
1034
+ });
1035
+ $[64] = t31;
1036
+ $[65] = t32;
1037
+ } else t32 = $[65];
1038
+ let t33;
1039
+ if ($[66] !== fieldIds.mode || $[67] !== mode || $[68] !== t28 || $[69] !== t30 || $[70] !== t32) {
1040
+ t33 = /* @__PURE__ */ jsxs("select", {
1018
1041
  className: DIALOG_INPUT_CLASS,
1019
- id: t24,
1020
- onChange: t25,
1042
+ id: t25,
1043
+ onChange: t26,
1021
1044
  value: mode,
1022
1045
  children: [
1023
- t27,
1024
- t29,
1025
- t31
1046
+ t28,
1047
+ t30,
1048
+ t32
1026
1049
  ]
1027
1050
  });
1028
- $[64] = fieldIds.mode;
1029
- $[65] = mode;
1030
- $[66] = t27;
1031
- $[67] = t29;
1032
- $[68] = t31;
1033
- $[69] = t32;
1034
- } else t32 = $[69];
1035
- let t33;
1036
- if ($[70] !== fieldIds.mode || $[71] !== t23 || $[72] !== t32) {
1037
- t33 = /* @__PURE__ */ jsxs("label", {
1051
+ $[66] = fieldIds.mode;
1052
+ $[67] = mode;
1053
+ $[68] = t28;
1054
+ $[69] = t30;
1055
+ $[70] = t32;
1056
+ $[71] = t33;
1057
+ } else t33 = $[71];
1058
+ let t34;
1059
+ if ($[72] !== fieldIds.mode || $[73] !== t24 || $[74] !== t33) {
1060
+ t34 = /* @__PURE__ */ jsxs("label", {
1038
1061
  className: "flex flex-col gap-1",
1039
- htmlFor: t21,
1040
- children: [t23, t32]
1062
+ htmlFor: t22,
1063
+ children: [t24, t33]
1041
1064
  });
1042
- $[70] = fieldIds.mode;
1043
- $[71] = t23;
1044
- $[72] = t32;
1045
- $[73] = t33;
1046
- } else t33 = $[73];
1047
- let t34;
1048
- if ($[74] !== color || $[75] !== diagonal || $[76] !== fieldIds.color || $[77] !== fieldIds.diagonal || $[78] !== fieldIds.font || $[79] !== fieldIds.opacity || $[80] !== fieldIds.text || $[81] !== font || $[82] !== mode || $[83] !== opacityPercent || $[84] !== t || $[85] !== text) {
1049
- t34 = mode === "text" && /* @__PURE__ */ jsxs("div", {
1065
+ $[72] = fieldIds.mode;
1066
+ $[73] = t24;
1067
+ $[74] = t33;
1068
+ $[75] = t34;
1069
+ } else t34 = $[75];
1070
+ let t35;
1071
+ if ($[76] !== color || $[77] !== diagonal || $[78] !== fieldIds.color || $[79] !== fieldIds.diagonal || $[80] !== fieldIds.font || $[81] !== fieldIds.opacity || $[82] !== fieldIds.text || $[83] !== font || $[84] !== mode || $[85] !== opacityPercent || $[86] !== t || $[87] !== text) {
1072
+ t35 = mode === "text" && /* @__PURE__ */ jsxs("div", {
1050
1073
  className: "grid grid-cols-2 gap-3",
1051
1074
  children: [
1052
1075
  /* @__PURE__ */ jsxs("label", {
@@ -1120,23 +1143,23 @@ function WatermarkDialog(t0) {
1120
1143
  })
1121
1144
  ]
1122
1145
  });
1123
- $[74] = color;
1124
- $[75] = diagonal;
1125
- $[76] = fieldIds.color;
1126
- $[77] = fieldIds.diagonal;
1127
- $[78] = fieldIds.font;
1128
- $[79] = fieldIds.opacity;
1129
- $[80] = fieldIds.text;
1130
- $[81] = font;
1131
- $[82] = mode;
1132
- $[83] = opacityPercent;
1133
- $[84] = t;
1134
- $[85] = text;
1135
- $[86] = t34;
1136
- } else t34 = $[86];
1137
- let t35;
1138
- if ($[87] !== fieldIds.imageRId || $[88] !== fieldIds.imageTarget || $[89] !== fieldIds.imageTargetExternal || $[90] !== fieldIds.scale || $[91] !== fieldIds.washout || $[92] !== imageRId || $[93] !== imageTarget || $[94] !== imageTargetError || $[95] !== imageTargetExternal || $[96] !== mode || $[97] !== scalePercent || $[98] !== t || $[99] !== washout) {
1139
- t35 = mode === "picture" && /* @__PURE__ */ jsxs("div", {
1146
+ $[76] = color;
1147
+ $[77] = diagonal;
1148
+ $[78] = fieldIds.color;
1149
+ $[79] = fieldIds.diagonal;
1150
+ $[80] = fieldIds.font;
1151
+ $[81] = fieldIds.opacity;
1152
+ $[82] = fieldIds.text;
1153
+ $[83] = font;
1154
+ $[84] = mode;
1155
+ $[85] = opacityPercent;
1156
+ $[86] = t;
1157
+ $[87] = text;
1158
+ $[88] = t35;
1159
+ } else t35 = $[88];
1160
+ let t36;
1161
+ if ($[89] !== fieldIds.imageRId || $[90] !== fieldIds.imageTarget || $[91] !== fieldIds.imageTargetExternal || $[92] !== fieldIds.scale || $[93] !== fieldIds.washout || $[94] !== imageRId || $[95] !== imageTarget || $[96] !== imageTargetError || $[97] !== imageTargetExternal || $[98] !== mode || $[99] !== scalePercent || $[100] !== t || $[101] !== washout) {
1162
+ t36 = mode === "picture" && /* @__PURE__ */ jsxs("div", {
1140
1163
  className: "grid grid-cols-2 gap-3",
1141
1164
  children: [
1142
1165
  /* @__PURE__ */ jsxs("label", {
@@ -1219,121 +1242,121 @@ function WatermarkDialog(t0) {
1219
1242
  })
1220
1243
  ]
1221
1244
  });
1222
- $[87] = fieldIds.imageRId;
1223
- $[88] = fieldIds.imageTarget;
1224
- $[89] = fieldIds.imageTargetExternal;
1225
- $[90] = fieldIds.scale;
1226
- $[91] = fieldIds.washout;
1227
- $[92] = imageRId;
1228
- $[93] = imageTarget;
1229
- $[94] = imageTargetError;
1230
- $[95] = imageTargetExternal;
1231
- $[96] = mode;
1232
- $[97] = scalePercent;
1233
- $[98] = t;
1234
- $[99] = washout;
1235
- $[100] = t35;
1236
- } else t35 = $[100];
1237
- let t36;
1238
- if ($[101] !== t33 || $[102] !== t34 || $[103] !== t35) {
1239
- t36 = /* @__PURE__ */ jsxs("div", {
1245
+ $[89] = fieldIds.imageRId;
1246
+ $[90] = fieldIds.imageTarget;
1247
+ $[91] = fieldIds.imageTargetExternal;
1248
+ $[92] = fieldIds.scale;
1249
+ $[93] = fieldIds.washout;
1250
+ $[94] = imageRId;
1251
+ $[95] = imageTarget;
1252
+ $[96] = imageTargetError;
1253
+ $[97] = imageTargetExternal;
1254
+ $[98] = mode;
1255
+ $[99] = scalePercent;
1256
+ $[100] = t;
1257
+ $[101] = washout;
1258
+ $[102] = t36;
1259
+ } else t36 = $[102];
1260
+ let t37;
1261
+ if ($[103] !== t34 || $[104] !== t35 || $[105] !== t36) {
1262
+ t37 = /* @__PURE__ */ jsxs("div", {
1240
1263
  className: DIALOG_BODY_CLASS,
1241
1264
  children: [
1242
- t33,
1243
1265
  t34,
1244
- t35
1266
+ t35,
1267
+ t36
1245
1268
  ]
1246
1269
  });
1247
- $[101] = t33;
1248
- $[102] = t34;
1249
- $[103] = t35;
1250
- $[104] = t36;
1251
- } else t36 = $[104];
1252
- let t37;
1253
- if ($[105] !== t) {
1254
- t37 = t("common.cancel");
1255
- $[105] = t;
1270
+ $[103] = t34;
1271
+ $[104] = t35;
1272
+ $[105] = t36;
1256
1273
  $[106] = t37;
1257
1274
  } else t37 = $[106];
1258
1275
  let t38;
1259
- if ($[107] !== DialogClose || $[108] !== t37) {
1260
- t38 = /* @__PURE__ */ jsx(DialogClose, {
1276
+ if ($[107] !== t) {
1277
+ t38 = t("common.cancel");
1278
+ $[107] = t;
1279
+ $[108] = t38;
1280
+ } else t38 = $[108];
1281
+ let t39;
1282
+ if ($[109] !== DialogClose || $[110] !== t38) {
1283
+ t39 = /* @__PURE__ */ jsx(DialogClose, {
1261
1284
  className: DIALOG_SECONDARY_BUTTON_CLASS,
1262
- children: t37
1285
+ children: t38
1263
1286
  });
1264
- $[107] = DialogClose;
1265
- $[108] = t37;
1266
- $[109] = t38;
1267
- } else t38 = $[109];
1268
- const t39 = !canApply;
1269
- let t40;
1270
- if ($[110] !== t) {
1271
- t40 = t("common.apply");
1272
- $[110] = t;
1273
- $[111] = t40;
1274
- } else t40 = $[111];
1287
+ $[109] = DialogClose;
1288
+ $[110] = t38;
1289
+ $[111] = t39;
1290
+ } else t39 = $[111];
1291
+ const t40 = !canApply;
1275
1292
  let t41;
1276
- if ($[112] !== handleApply || $[113] !== t39 || $[114] !== t40) {
1277
- t41 = /* @__PURE__ */ jsx("button", {
1293
+ if ($[112] !== t) {
1294
+ t41 = t("common.apply");
1295
+ $[112] = t;
1296
+ $[113] = t41;
1297
+ } else t41 = $[113];
1298
+ let t42;
1299
+ if ($[114] !== handleApply || $[115] !== t40 || $[116] !== t41) {
1300
+ t42 = /* @__PURE__ */ jsx("button", {
1278
1301
  className: DIALOG_PRIMARY_BUTTON_CLASS,
1279
- disabled: t39,
1302
+ disabled: t40,
1280
1303
  onClick: handleApply,
1281
1304
  type: "button",
1282
- children: t40
1305
+ children: t41
1283
1306
  });
1284
- $[112] = handleApply;
1285
- $[113] = t39;
1286
- $[114] = t40;
1287
- $[115] = t41;
1288
- } else t41 = $[115];
1289
- let t42;
1290
- if ($[116] !== t38 || $[117] !== t41) {
1291
- t42 = /* @__PURE__ */ jsxs("div", {
1307
+ $[114] = handleApply;
1308
+ $[115] = t40;
1309
+ $[116] = t41;
1310
+ $[117] = t42;
1311
+ } else t42 = $[117];
1312
+ let t43;
1313
+ if ($[118] !== t39 || $[119] !== t42) {
1314
+ t43 = /* @__PURE__ */ jsxs("div", {
1292
1315
  className: DIALOG_FOOTER_CLASS,
1293
- children: [t38, t41]
1316
+ children: [t39, t42]
1294
1317
  });
1295
- $[116] = t38;
1296
- $[117] = t41;
1297
- $[118] = t42;
1298
- } else t42 = $[118];
1299
- let t43;
1300
- if ($[119] !== DialogPopup || $[120] !== t20 || $[121] !== t36 || $[122] !== t42) {
1301
- t43 = /* @__PURE__ */ jsxs(DialogPopup, {
1318
+ $[118] = t39;
1319
+ $[119] = t42;
1320
+ $[120] = t43;
1321
+ } else t43 = $[120];
1322
+ let t44;
1323
+ if ($[121] !== DialogPopup || $[122] !== t21 || $[123] !== t37 || $[124] !== t43) {
1324
+ t44 = /* @__PURE__ */ jsxs(DialogPopup, {
1302
1325
  className: DIALOG_POPUP_CLASS,
1303
1326
  children: [
1304
- t20,
1305
- t36,
1306
- t42
1327
+ t21,
1328
+ t37,
1329
+ t43
1307
1330
  ]
1308
1331
  });
1309
- $[119] = DialogPopup;
1310
- $[120] = t20;
1311
- $[121] = t36;
1312
- $[122] = t42;
1313
- $[123] = t43;
1314
- } else t43 = $[123];
1315
- let t44;
1316
- if ($[124] !== DialogPortal || $[125] !== t18 || $[126] !== t43) {
1317
- t44 = /* @__PURE__ */ jsxs(DialogPortal, { children: [t18, t43] });
1318
- $[124] = DialogPortal;
1319
- $[125] = t18;
1320
- $[126] = t43;
1321
- $[127] = t44;
1322
- } else t44 = $[127];
1332
+ $[121] = DialogPopup;
1333
+ $[122] = t21;
1334
+ $[123] = t37;
1335
+ $[124] = t43;
1336
+ $[125] = t44;
1337
+ } else t44 = $[125];
1323
1338
  let t45;
1324
- if ($[128] !== Dialog || $[129] !== handleOpenChange || $[130] !== isOpen || $[131] !== t44) {
1325
- t45 = /* @__PURE__ */ jsx(Dialog, {
1339
+ if ($[126] !== DialogPortal || $[127] !== t19 || $[128] !== t44) {
1340
+ t45 = /* @__PURE__ */ jsxs(DialogPortal, { children: [t19, t44] });
1341
+ $[126] = DialogPortal;
1342
+ $[127] = t19;
1343
+ $[128] = t44;
1344
+ $[129] = t45;
1345
+ } else t45 = $[129];
1346
+ let t46;
1347
+ if ($[130] !== Dialog || $[131] !== handleOpenChange || $[132] !== isOpen || $[133] !== t45) {
1348
+ t46 = /* @__PURE__ */ jsx(Dialog, {
1326
1349
  open: isOpen,
1327
1350
  onOpenChange: handleOpenChange,
1328
- children: t44
1351
+ children: t45
1329
1352
  });
1330
- $[128] = Dialog;
1331
- $[129] = handleOpenChange;
1332
- $[130] = isOpen;
1333
- $[131] = t44;
1334
- $[132] = t45;
1335
- } else t45 = $[132];
1336
- return t45;
1353
+ $[130] = Dialog;
1354
+ $[131] = handleOpenChange;
1355
+ $[132] = isOpen;
1356
+ $[133] = t45;
1357
+ $[134] = t46;
1358
+ } else t46 = $[134];
1359
+ return t46;
1337
1360
  }
1338
1361
  function toWatermarkMode(value) {
1339
1362
  if (value === "none" || value === "picture" || value === "text") return value;