@stll/folio-react 0.6.0 → 0.8.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.
- package/dist/{CommentsSidebar-_utmEkA9.js → CommentsSidebar-Byn5lyrt.js} +127 -130
- package/dist/{FindReplaceDialog-DLdBekSR.js → FindReplaceDialog-CqKK82nE.js} +23 -18
- package/dist/FootnotePropertiesDialog-CixRdIiT.js +822 -0
- package/dist/ImagePositionDialog-DNodkoI2.js +1065 -0
- package/dist/ImagePropertiesDialog-CLsDIUWb.js +613 -0
- package/dist/InsertSymbolDialog-DCFLmfzn.js +376 -0
- package/dist/PageSetupDialog-COkgeOQn.js +820 -0
- package/dist/TablePropertiesDialog-B_AGrPR8.js +434 -0
- package/dist/{TextContextMenu-CG0V37wi.js → TextContextMenu-Ci7-M4oU.js} +199 -79
- package/dist/compat/eigenpal.d.ts +1 -1
- package/dist/compat/eigenpal.js +89 -17
- package/dist/dialogChrome-BoGYPgeu.js +26 -0
- package/dist/{dialogs-CzvXYJyG.js → dialogs-Bj2PdycR.js} +608 -352
- package/dist/{dialogs-j7qyw17x.d.ts → dialogs-DK8OVUT_.d.ts} +13 -1
- package/dist/dialogs.d.ts +2 -2
- package/dist/dialogs.js +9 -8
- package/dist/editor.css +1 -1
- package/dist/folio-ui-BgDDRsUX.js +1013 -0
- package/dist/index.d.ts +5 -4
- package/dist/index.js +12 -11
- package/dist/{renderAsync-B7UJsZye.d.ts → renderAsync-BmxQE7iO.d.ts} +12 -3
- package/dist/{renderAsync-CwHTsxBN.js → renderAsync-BtWYvQMT.js} +5717 -3275
- package/dist/standalone.css +1 -1
- package/package.json +8 -6
- package/dist/FootnotePropertiesDialog-CUjq9c6H.js +0 -267
- package/dist/ImagePositionDialog-BMuO9rLT.js +0 -395
- package/dist/ImagePropertiesDialog-C8iEgdmN.js +0 -198
- package/dist/PageSetupDialog-BKsSMCGb.js +0 -312
- package/dist/TablePropertiesDialog-Dw8gvL78.js +0 -159
- package/dist/useFindReplace-BPBpMWS9.js +0 -842
|
@@ -0,0 +1,1065 @@
|
|
|
1
|
+
import { t as __exportAll } from "./rolldown-runtime-BBjsoOtd.js";
|
|
2
|
+
import { r as useFolioUI } from "./folio-ui-BgDDRsUX.js";
|
|
3
|
+
import { u as useCloseOnDialogOpenChange } from "./dialogChrome-BoGYPgeu.js";
|
|
4
|
+
import { c } from "react-compiler-runtime";
|
|
5
|
+
import { useEffect, useId, useState } from "react";
|
|
6
|
+
import { useTranslations } from "use-intl";
|
|
7
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
8
|
+
//#region src/components/dialogs/ImagePositionDialog.tsx
|
|
9
|
+
/**
|
|
10
|
+
* Image Position Dialog
|
|
11
|
+
*
|
|
12
|
+
* Modal for editing image positioning settings:
|
|
13
|
+
* - Horizontal: alignment or offset, relative to page/column/margin/paragraph
|
|
14
|
+
* - Vertical: alignment or offset, relative to page/margin/paragraph/line
|
|
15
|
+
* - Distance from text (top/bottom/left/right)
|
|
16
|
+
*/
|
|
17
|
+
var ImagePositionDialog_exports = /* @__PURE__ */ __exportAll({ ImagePositionDialog: () => ImagePositionDialog });
|
|
18
|
+
function ImagePositionDialog(t0) {
|
|
19
|
+
const $ = c(277);
|
|
20
|
+
const { isOpen, onClose, onApply, currentData } = t0;
|
|
21
|
+
const { Root: Dialog, Portal: DialogPortal, Backdrop: DialogBackdrop, Popup: DialogPopup, Title: DialogTitle, Close: DialogClose } = useFolioUI().Dialog;
|
|
22
|
+
const handleOpenChange = useCloseOnDialogOpenChange(onClose);
|
|
23
|
+
const t = useTranslations("folio");
|
|
24
|
+
const id = useId();
|
|
25
|
+
const [hMode, setHMode] = useState("align");
|
|
26
|
+
const [hAlign, setHAlign] = useState("center");
|
|
27
|
+
const [hRelativeTo, setHRelativeTo] = useState("column");
|
|
28
|
+
const [hOffset, setHOffset] = useState(0);
|
|
29
|
+
const [vMode, setVMode] = useState("align");
|
|
30
|
+
const [vAlign, setVAlign] = useState("top");
|
|
31
|
+
const [vRelativeTo, setVRelativeTo] = useState("paragraph");
|
|
32
|
+
const [vOffset, setVOffset] = useState(0);
|
|
33
|
+
const [distTop, setDistTop] = useState(0);
|
|
34
|
+
const [distBottom, setDistBottom] = useState(0);
|
|
35
|
+
const [distLeft, setDistLeft] = useState(0);
|
|
36
|
+
const [distRight, setDistRight] = useState(0);
|
|
37
|
+
let t1;
|
|
38
|
+
if ($[0] !== currentData?.distBottom || $[1] !== currentData?.distLeft || $[2] !== currentData?.distRight || $[3] !== currentData?.distTop || $[4] !== currentData?.horizontal || $[5] !== currentData?.vertical || $[6] !== isOpen) {
|
|
39
|
+
t1 = () => {
|
|
40
|
+
if (!isOpen) return;
|
|
41
|
+
const h = currentData?.horizontal;
|
|
42
|
+
const v = currentData?.vertical;
|
|
43
|
+
if (h?.align) {
|
|
44
|
+
setHMode("align");
|
|
45
|
+
setHAlign(h.align);
|
|
46
|
+
} else if (h?.posOffset !== void 0) {
|
|
47
|
+
setHMode("offset");
|
|
48
|
+
setHOffset(h.posOffset);
|
|
49
|
+
}
|
|
50
|
+
if (h?.relativeTo) setHRelativeTo(h.relativeTo);
|
|
51
|
+
if (v?.align) {
|
|
52
|
+
setVMode("align");
|
|
53
|
+
setVAlign(v.align);
|
|
54
|
+
} else if (v?.posOffset !== void 0) {
|
|
55
|
+
setVMode("offset");
|
|
56
|
+
setVOffset(v.posOffset);
|
|
57
|
+
}
|
|
58
|
+
if (v?.relativeTo) setVRelativeTo(v.relativeTo);
|
|
59
|
+
setDistTop(currentData?.distTop ?? 0);
|
|
60
|
+
setDistBottom(currentData?.distBottom ?? 0);
|
|
61
|
+
setDistLeft(currentData?.distLeft ?? 0);
|
|
62
|
+
setDistRight(currentData?.distRight ?? 0);
|
|
63
|
+
};
|
|
64
|
+
$[0] = currentData?.distBottom;
|
|
65
|
+
$[1] = currentData?.distLeft;
|
|
66
|
+
$[2] = currentData?.distRight;
|
|
67
|
+
$[3] = currentData?.distTop;
|
|
68
|
+
$[4] = currentData?.horizontal;
|
|
69
|
+
$[5] = currentData?.vertical;
|
|
70
|
+
$[6] = isOpen;
|
|
71
|
+
$[7] = t1;
|
|
72
|
+
} else t1 = $[7];
|
|
73
|
+
let t2;
|
|
74
|
+
if ($[8] !== currentData || $[9] !== isOpen) {
|
|
75
|
+
t2 = [isOpen, currentData];
|
|
76
|
+
$[8] = currentData;
|
|
77
|
+
$[9] = isOpen;
|
|
78
|
+
$[10] = t2;
|
|
79
|
+
} else t2 = $[10];
|
|
80
|
+
useEffect(t1, t2);
|
|
81
|
+
let t3;
|
|
82
|
+
if ($[11] !== distBottom || $[12] !== distLeft || $[13] !== distRight || $[14] !== distTop || $[15] !== hAlign || $[16] !== hMode || $[17] !== hOffset || $[18] !== hRelativeTo || $[19] !== onApply || $[20] !== onClose || $[21] !== vAlign || $[22] !== vMode || $[23] !== vOffset || $[24] !== vRelativeTo) {
|
|
83
|
+
t3 = () => {
|
|
84
|
+
const data = {};
|
|
85
|
+
data.horizontal = {
|
|
86
|
+
relativeTo: hRelativeTo,
|
|
87
|
+
...hMode === "align" ? { align: hAlign } : { posOffset: hOffset }
|
|
88
|
+
};
|
|
89
|
+
data.vertical = {
|
|
90
|
+
relativeTo: vRelativeTo,
|
|
91
|
+
...vMode === "align" ? { align: vAlign } : { posOffset: vOffset }
|
|
92
|
+
};
|
|
93
|
+
data.distTop = distTop;
|
|
94
|
+
data.distBottom = distBottom;
|
|
95
|
+
data.distLeft = distLeft;
|
|
96
|
+
data.distRight = distRight;
|
|
97
|
+
onApply(data);
|
|
98
|
+
onClose();
|
|
99
|
+
};
|
|
100
|
+
$[11] = distBottom;
|
|
101
|
+
$[12] = distLeft;
|
|
102
|
+
$[13] = distRight;
|
|
103
|
+
$[14] = distTop;
|
|
104
|
+
$[15] = hAlign;
|
|
105
|
+
$[16] = hMode;
|
|
106
|
+
$[17] = hOffset;
|
|
107
|
+
$[18] = hRelativeTo;
|
|
108
|
+
$[19] = onApply;
|
|
109
|
+
$[20] = onClose;
|
|
110
|
+
$[21] = vAlign;
|
|
111
|
+
$[22] = vMode;
|
|
112
|
+
$[23] = vOffset;
|
|
113
|
+
$[24] = vRelativeTo;
|
|
114
|
+
$[25] = t3;
|
|
115
|
+
} else t3 = $[25];
|
|
116
|
+
const handleApply = t3;
|
|
117
|
+
const t4 = `${id}-img-pos-h-mode`;
|
|
118
|
+
const t5 = `${id}-img-pos-h-align`;
|
|
119
|
+
const t6 = `${id}-img-pos-h-offset`;
|
|
120
|
+
const t7 = `${id}-img-pos-h-rel`;
|
|
121
|
+
const t8 = `${id}-img-pos-v-mode`;
|
|
122
|
+
const t9 = `${id}-img-pos-v-align`;
|
|
123
|
+
const t10 = `${id}-img-pos-v-offset`;
|
|
124
|
+
const t11 = `${id}-img-pos-v-rel`;
|
|
125
|
+
const t12 = `${id}-img-pos-dist-top`;
|
|
126
|
+
const t13 = `${id}-img-pos-dist-bottom`;
|
|
127
|
+
const t14 = `${id}-img-pos-dist-left`;
|
|
128
|
+
const t15 = `${id}-img-pos-dist-right`;
|
|
129
|
+
let t16;
|
|
130
|
+
if ($[26] !== t10 || $[27] !== t11 || $[28] !== t12 || $[29] !== t13 || $[30] !== t14 || $[31] !== t15 || $[32] !== t4 || $[33] !== t5 || $[34] !== t6 || $[35] !== t7 || $[36] !== t8 || $[37] !== t9) {
|
|
131
|
+
t16 = {
|
|
132
|
+
hMode: t4,
|
|
133
|
+
hAlign: t5,
|
|
134
|
+
hOffset: t6,
|
|
135
|
+
hRelativeTo: t7,
|
|
136
|
+
vMode: t8,
|
|
137
|
+
vAlign: t9,
|
|
138
|
+
vOffset: t10,
|
|
139
|
+
vRelativeTo: t11,
|
|
140
|
+
distTop: t12,
|
|
141
|
+
distBottom: t13,
|
|
142
|
+
distLeft: t14,
|
|
143
|
+
distRight: t15
|
|
144
|
+
};
|
|
145
|
+
$[26] = t10;
|
|
146
|
+
$[27] = t11;
|
|
147
|
+
$[28] = t12;
|
|
148
|
+
$[29] = t13;
|
|
149
|
+
$[30] = t14;
|
|
150
|
+
$[31] = t15;
|
|
151
|
+
$[32] = t4;
|
|
152
|
+
$[33] = t5;
|
|
153
|
+
$[34] = t6;
|
|
154
|
+
$[35] = t7;
|
|
155
|
+
$[36] = t8;
|
|
156
|
+
$[37] = t9;
|
|
157
|
+
$[38] = t16;
|
|
158
|
+
} else t16 = $[38];
|
|
159
|
+
const fieldIds = t16;
|
|
160
|
+
let t17;
|
|
161
|
+
if ($[39] !== DialogBackdrop) {
|
|
162
|
+
t17 = /* @__PURE__ */ jsx(DialogBackdrop, { className: "fixed inset-0 z-[10000] bg-black/50" });
|
|
163
|
+
$[39] = DialogBackdrop;
|
|
164
|
+
$[40] = t17;
|
|
165
|
+
} else t17 = $[40];
|
|
166
|
+
let t18;
|
|
167
|
+
if ($[41] !== t) {
|
|
168
|
+
t18 = t("dialogs.imagePosition.title");
|
|
169
|
+
$[41] = t;
|
|
170
|
+
$[42] = t18;
|
|
171
|
+
} else t18 = $[42];
|
|
172
|
+
let t19;
|
|
173
|
+
if ($[43] !== DialogTitle || $[44] !== t18) {
|
|
174
|
+
t19 = /* @__PURE__ */ jsx(DialogTitle, {
|
|
175
|
+
className: "border-b px-5 py-3 text-base font-semibold",
|
|
176
|
+
children: t18
|
|
177
|
+
});
|
|
178
|
+
$[43] = DialogTitle;
|
|
179
|
+
$[44] = t18;
|
|
180
|
+
$[45] = t19;
|
|
181
|
+
} else t19 = $[45];
|
|
182
|
+
let t20;
|
|
183
|
+
if ($[46] !== t) {
|
|
184
|
+
t20 = t("dialogs.imagePosition.horizontal");
|
|
185
|
+
$[46] = t;
|
|
186
|
+
$[47] = t20;
|
|
187
|
+
} else t20 = $[47];
|
|
188
|
+
let t21;
|
|
189
|
+
if ($[48] !== t20) {
|
|
190
|
+
t21 = /* @__PURE__ */ jsx("div", {
|
|
191
|
+
className: "text-foreground text-[13px] font-semibold",
|
|
192
|
+
children: t20
|
|
193
|
+
});
|
|
194
|
+
$[48] = t20;
|
|
195
|
+
$[49] = t21;
|
|
196
|
+
} else t21 = $[49];
|
|
197
|
+
const t22 = fieldIds.hMode;
|
|
198
|
+
let t23;
|
|
199
|
+
if ($[50] !== t) {
|
|
200
|
+
t23 = t("dialogs.imagePosition.position");
|
|
201
|
+
$[50] = t;
|
|
202
|
+
$[51] = t23;
|
|
203
|
+
} else t23 = $[51];
|
|
204
|
+
let t24;
|
|
205
|
+
if ($[52] !== fieldIds.hMode || $[53] !== t23) {
|
|
206
|
+
t24 = /* @__PURE__ */ jsx("label", {
|
|
207
|
+
className: "w-[75px] text-muted-foreground text-xs",
|
|
208
|
+
htmlFor: t22,
|
|
209
|
+
children: t23
|
|
210
|
+
});
|
|
211
|
+
$[52] = fieldIds.hMode;
|
|
212
|
+
$[53] = t23;
|
|
213
|
+
$[54] = t24;
|
|
214
|
+
} else t24 = $[54];
|
|
215
|
+
const t25 = fieldIds.hMode;
|
|
216
|
+
let t26;
|
|
217
|
+
if ($[55] === Symbol.for("react.memo_cache_sentinel")) {
|
|
218
|
+
t26 = (e) => setHMode(e.target.value);
|
|
219
|
+
$[55] = t26;
|
|
220
|
+
} else t26 = $[55];
|
|
221
|
+
let t27;
|
|
222
|
+
if ($[56] !== t) {
|
|
223
|
+
t27 = t("dialogs.imagePosition.alignment");
|
|
224
|
+
$[56] = t;
|
|
225
|
+
$[57] = t27;
|
|
226
|
+
} else t27 = $[57];
|
|
227
|
+
let t28;
|
|
228
|
+
if ($[58] !== t27) {
|
|
229
|
+
t28 = /* @__PURE__ */ jsx("option", {
|
|
230
|
+
value: "align",
|
|
231
|
+
children: t27
|
|
232
|
+
});
|
|
233
|
+
$[58] = t27;
|
|
234
|
+
$[59] = t28;
|
|
235
|
+
} else t28 = $[59];
|
|
236
|
+
let t29;
|
|
237
|
+
if ($[60] !== t) {
|
|
238
|
+
t29 = t("dialogs.imagePosition.offset");
|
|
239
|
+
$[60] = t;
|
|
240
|
+
$[61] = t29;
|
|
241
|
+
} else t29 = $[61];
|
|
242
|
+
let t30;
|
|
243
|
+
if ($[62] !== t29) {
|
|
244
|
+
t30 = /* @__PURE__ */ jsx("option", {
|
|
245
|
+
value: "offset",
|
|
246
|
+
children: t29
|
|
247
|
+
});
|
|
248
|
+
$[62] = t29;
|
|
249
|
+
$[63] = t30;
|
|
250
|
+
} else t30 = $[63];
|
|
251
|
+
let t31;
|
|
252
|
+
if ($[64] !== fieldIds.hMode || $[65] !== hMode || $[66] !== t28 || $[67] !== t30) {
|
|
253
|
+
t31 = /* @__PURE__ */ jsxs("select", {
|
|
254
|
+
className: "border-input bg-background text-foreground flex-1 rounded border px-1.5 py-1 text-xs outline-none",
|
|
255
|
+
id: t25,
|
|
256
|
+
value: hMode,
|
|
257
|
+
onChange: t26,
|
|
258
|
+
children: [t28, t30]
|
|
259
|
+
});
|
|
260
|
+
$[64] = fieldIds.hMode;
|
|
261
|
+
$[65] = hMode;
|
|
262
|
+
$[66] = t28;
|
|
263
|
+
$[67] = t30;
|
|
264
|
+
$[68] = t31;
|
|
265
|
+
} else t31 = $[68];
|
|
266
|
+
let t32;
|
|
267
|
+
if ($[69] !== t24 || $[70] !== t31) {
|
|
268
|
+
t32 = /* @__PURE__ */ jsxs("div", {
|
|
269
|
+
className: "flex items-center gap-2",
|
|
270
|
+
children: [t24, t31]
|
|
271
|
+
});
|
|
272
|
+
$[69] = t24;
|
|
273
|
+
$[70] = t31;
|
|
274
|
+
$[71] = t32;
|
|
275
|
+
} else t32 = $[71];
|
|
276
|
+
let t33;
|
|
277
|
+
if ($[72] !== fieldIds.hAlign || $[73] !== fieldIds.hOffset || $[74] !== hAlign || $[75] !== hMode || $[76] !== hOffset || $[77] !== t) {
|
|
278
|
+
t33 = hMode === "align" ? /* @__PURE__ */ jsxs("div", {
|
|
279
|
+
className: "flex items-center gap-2",
|
|
280
|
+
children: [/* @__PURE__ */ jsx("label", {
|
|
281
|
+
className: "w-[75px] text-muted-foreground text-xs",
|
|
282
|
+
htmlFor: fieldIds.hAlign,
|
|
283
|
+
children: t("dialogs.imagePosition.align")
|
|
284
|
+
}), /* @__PURE__ */ jsxs("select", {
|
|
285
|
+
className: "border-input bg-background text-foreground flex-1 rounded border px-1.5 py-1 text-xs outline-none",
|
|
286
|
+
id: fieldIds.hAlign,
|
|
287
|
+
value: hAlign,
|
|
288
|
+
onChange: (e_0) => setHAlign(e_0.target.value),
|
|
289
|
+
children: [
|
|
290
|
+
/* @__PURE__ */ jsx("option", {
|
|
291
|
+
value: "left",
|
|
292
|
+
children: t("dialogs.imagePosition.alignOptions.left")
|
|
293
|
+
}),
|
|
294
|
+
/* @__PURE__ */ jsx("option", {
|
|
295
|
+
value: "center",
|
|
296
|
+
children: t("dialogs.imagePosition.alignOptions.center")
|
|
297
|
+
}),
|
|
298
|
+
/* @__PURE__ */ jsx("option", {
|
|
299
|
+
value: "right",
|
|
300
|
+
children: t("dialogs.imagePosition.alignOptions.right")
|
|
301
|
+
})
|
|
302
|
+
]
|
|
303
|
+
})]
|
|
304
|
+
}) : /* @__PURE__ */ jsxs("div", {
|
|
305
|
+
className: "flex items-center gap-2",
|
|
306
|
+
children: [/* @__PURE__ */ jsx("label", {
|
|
307
|
+
className: "w-[75px] text-muted-foreground text-xs",
|
|
308
|
+
htmlFor: fieldIds.hOffset,
|
|
309
|
+
children: t("dialogs.imagePosition.offsetPx")
|
|
310
|
+
}), /* @__PURE__ */ jsx("input", {
|
|
311
|
+
className: "border-input bg-background text-foreground flex-1 rounded border px-1.5 py-1 text-xs outline-none",
|
|
312
|
+
id: fieldIds.hOffset,
|
|
313
|
+
type: "number",
|
|
314
|
+
value: hOffset,
|
|
315
|
+
onChange: (e_1) => setHOffset(Number(e_1.target.value) || 0)
|
|
316
|
+
})]
|
|
317
|
+
});
|
|
318
|
+
$[72] = fieldIds.hAlign;
|
|
319
|
+
$[73] = fieldIds.hOffset;
|
|
320
|
+
$[74] = hAlign;
|
|
321
|
+
$[75] = hMode;
|
|
322
|
+
$[76] = hOffset;
|
|
323
|
+
$[77] = t;
|
|
324
|
+
$[78] = t33;
|
|
325
|
+
} else t33 = $[78];
|
|
326
|
+
const t34 = fieldIds.hRelativeTo;
|
|
327
|
+
let t35;
|
|
328
|
+
if ($[79] !== t) {
|
|
329
|
+
t35 = t("dialogs.imagePosition.relativeTo");
|
|
330
|
+
$[79] = t;
|
|
331
|
+
$[80] = t35;
|
|
332
|
+
} else t35 = $[80];
|
|
333
|
+
let t36;
|
|
334
|
+
if ($[81] !== fieldIds.hRelativeTo || $[82] !== t35) {
|
|
335
|
+
t36 = /* @__PURE__ */ jsx("label", {
|
|
336
|
+
className: "w-[75px] text-muted-foreground text-xs",
|
|
337
|
+
htmlFor: t34,
|
|
338
|
+
children: t35
|
|
339
|
+
});
|
|
340
|
+
$[81] = fieldIds.hRelativeTo;
|
|
341
|
+
$[82] = t35;
|
|
342
|
+
$[83] = t36;
|
|
343
|
+
} else t36 = $[83];
|
|
344
|
+
const t37 = fieldIds.hRelativeTo;
|
|
345
|
+
let t38;
|
|
346
|
+
if ($[84] === Symbol.for("react.memo_cache_sentinel")) {
|
|
347
|
+
t38 = (e_2) => setHRelativeTo(e_2.target.value);
|
|
348
|
+
$[84] = t38;
|
|
349
|
+
} else t38 = $[84];
|
|
350
|
+
let t39;
|
|
351
|
+
if ($[85] !== t) {
|
|
352
|
+
t39 = t("dialogs.imagePosition.relativeOptions.page");
|
|
353
|
+
$[85] = t;
|
|
354
|
+
$[86] = t39;
|
|
355
|
+
} else t39 = $[86];
|
|
356
|
+
let t40;
|
|
357
|
+
if ($[87] !== t39) {
|
|
358
|
+
t40 = /* @__PURE__ */ jsx("option", {
|
|
359
|
+
value: "page",
|
|
360
|
+
children: t39
|
|
361
|
+
});
|
|
362
|
+
$[87] = t39;
|
|
363
|
+
$[88] = t40;
|
|
364
|
+
} else t40 = $[88];
|
|
365
|
+
let t41;
|
|
366
|
+
if ($[89] !== t) {
|
|
367
|
+
t41 = t("dialogs.imagePosition.relativeOptions.column");
|
|
368
|
+
$[89] = t;
|
|
369
|
+
$[90] = t41;
|
|
370
|
+
} else t41 = $[90];
|
|
371
|
+
let t42;
|
|
372
|
+
if ($[91] !== t41) {
|
|
373
|
+
t42 = /* @__PURE__ */ jsx("option", {
|
|
374
|
+
value: "column",
|
|
375
|
+
children: t41
|
|
376
|
+
});
|
|
377
|
+
$[91] = t41;
|
|
378
|
+
$[92] = t42;
|
|
379
|
+
} else t42 = $[92];
|
|
380
|
+
let t43;
|
|
381
|
+
if ($[93] !== t) {
|
|
382
|
+
t43 = t("dialogs.imagePosition.relativeOptions.margin");
|
|
383
|
+
$[93] = t;
|
|
384
|
+
$[94] = t43;
|
|
385
|
+
} else t43 = $[94];
|
|
386
|
+
let t44;
|
|
387
|
+
if ($[95] !== t43) {
|
|
388
|
+
t44 = /* @__PURE__ */ jsx("option", {
|
|
389
|
+
value: "margin",
|
|
390
|
+
children: t43
|
|
391
|
+
});
|
|
392
|
+
$[95] = t43;
|
|
393
|
+
$[96] = t44;
|
|
394
|
+
} else t44 = $[96];
|
|
395
|
+
let t45;
|
|
396
|
+
if ($[97] !== t) {
|
|
397
|
+
t45 = t("dialogs.imagePosition.relativeOptions.character");
|
|
398
|
+
$[97] = t;
|
|
399
|
+
$[98] = t45;
|
|
400
|
+
} else t45 = $[98];
|
|
401
|
+
let t46;
|
|
402
|
+
if ($[99] !== t45) {
|
|
403
|
+
t46 = /* @__PURE__ */ jsx("option", {
|
|
404
|
+
value: "character",
|
|
405
|
+
children: t45
|
|
406
|
+
});
|
|
407
|
+
$[99] = t45;
|
|
408
|
+
$[100] = t46;
|
|
409
|
+
} else t46 = $[100];
|
|
410
|
+
let t47;
|
|
411
|
+
if ($[101] !== fieldIds.hRelativeTo || $[102] !== hRelativeTo || $[103] !== t40 || $[104] !== t42 || $[105] !== t44 || $[106] !== t46) {
|
|
412
|
+
t47 = /* @__PURE__ */ jsxs("select", {
|
|
413
|
+
className: "border-input bg-background text-foreground flex-1 rounded border px-1.5 py-1 text-xs outline-none",
|
|
414
|
+
id: t37,
|
|
415
|
+
value: hRelativeTo,
|
|
416
|
+
onChange: t38,
|
|
417
|
+
children: [
|
|
418
|
+
t40,
|
|
419
|
+
t42,
|
|
420
|
+
t44,
|
|
421
|
+
t46
|
|
422
|
+
]
|
|
423
|
+
});
|
|
424
|
+
$[101] = fieldIds.hRelativeTo;
|
|
425
|
+
$[102] = hRelativeTo;
|
|
426
|
+
$[103] = t40;
|
|
427
|
+
$[104] = t42;
|
|
428
|
+
$[105] = t44;
|
|
429
|
+
$[106] = t46;
|
|
430
|
+
$[107] = t47;
|
|
431
|
+
} else t47 = $[107];
|
|
432
|
+
let t48;
|
|
433
|
+
if ($[108] !== t36 || $[109] !== t47) {
|
|
434
|
+
t48 = /* @__PURE__ */ jsxs("div", {
|
|
435
|
+
className: "flex items-center gap-2",
|
|
436
|
+
children: [t36, t47]
|
|
437
|
+
});
|
|
438
|
+
$[108] = t36;
|
|
439
|
+
$[109] = t47;
|
|
440
|
+
$[110] = t48;
|
|
441
|
+
} else t48 = $[110];
|
|
442
|
+
let t49;
|
|
443
|
+
if ($[111] !== t21 || $[112] !== t32 || $[113] !== t33 || $[114] !== t48) {
|
|
444
|
+
t49 = /* @__PURE__ */ jsxs("div", {
|
|
445
|
+
className: "flex flex-col gap-2",
|
|
446
|
+
children: [
|
|
447
|
+
t21,
|
|
448
|
+
t32,
|
|
449
|
+
t33,
|
|
450
|
+
t48
|
|
451
|
+
]
|
|
452
|
+
});
|
|
453
|
+
$[111] = t21;
|
|
454
|
+
$[112] = t32;
|
|
455
|
+
$[113] = t33;
|
|
456
|
+
$[114] = t48;
|
|
457
|
+
$[115] = t49;
|
|
458
|
+
} else t49 = $[115];
|
|
459
|
+
let t50;
|
|
460
|
+
if ($[116] !== t) {
|
|
461
|
+
t50 = t("dialogs.imagePosition.vertical");
|
|
462
|
+
$[116] = t;
|
|
463
|
+
$[117] = t50;
|
|
464
|
+
} else t50 = $[117];
|
|
465
|
+
let t51;
|
|
466
|
+
if ($[118] !== t50) {
|
|
467
|
+
t51 = /* @__PURE__ */ jsx("div", {
|
|
468
|
+
className: "text-foreground text-[13px] font-semibold",
|
|
469
|
+
children: t50
|
|
470
|
+
});
|
|
471
|
+
$[118] = t50;
|
|
472
|
+
$[119] = t51;
|
|
473
|
+
} else t51 = $[119];
|
|
474
|
+
const t52 = fieldIds.vMode;
|
|
475
|
+
let t53;
|
|
476
|
+
if ($[120] !== t) {
|
|
477
|
+
t53 = t("dialogs.imagePosition.position");
|
|
478
|
+
$[120] = t;
|
|
479
|
+
$[121] = t53;
|
|
480
|
+
} else t53 = $[121];
|
|
481
|
+
let t54;
|
|
482
|
+
if ($[122] !== fieldIds.vMode || $[123] !== t53) {
|
|
483
|
+
t54 = /* @__PURE__ */ jsx("label", {
|
|
484
|
+
className: "w-[75px] text-muted-foreground text-xs",
|
|
485
|
+
htmlFor: t52,
|
|
486
|
+
children: t53
|
|
487
|
+
});
|
|
488
|
+
$[122] = fieldIds.vMode;
|
|
489
|
+
$[123] = t53;
|
|
490
|
+
$[124] = t54;
|
|
491
|
+
} else t54 = $[124];
|
|
492
|
+
const t55 = fieldIds.vMode;
|
|
493
|
+
let t56;
|
|
494
|
+
if ($[125] === Symbol.for("react.memo_cache_sentinel")) {
|
|
495
|
+
t56 = (e_3) => setVMode(e_3.target.value);
|
|
496
|
+
$[125] = t56;
|
|
497
|
+
} else t56 = $[125];
|
|
498
|
+
let t57;
|
|
499
|
+
if ($[126] !== t) {
|
|
500
|
+
t57 = t("dialogs.imagePosition.alignment");
|
|
501
|
+
$[126] = t;
|
|
502
|
+
$[127] = t57;
|
|
503
|
+
} else t57 = $[127];
|
|
504
|
+
let t58;
|
|
505
|
+
if ($[128] !== t57) {
|
|
506
|
+
t58 = /* @__PURE__ */ jsx("option", {
|
|
507
|
+
value: "align",
|
|
508
|
+
children: t57
|
|
509
|
+
});
|
|
510
|
+
$[128] = t57;
|
|
511
|
+
$[129] = t58;
|
|
512
|
+
} else t58 = $[129];
|
|
513
|
+
let t59;
|
|
514
|
+
if ($[130] !== t) {
|
|
515
|
+
t59 = t("dialogs.imagePosition.offset");
|
|
516
|
+
$[130] = t;
|
|
517
|
+
$[131] = t59;
|
|
518
|
+
} else t59 = $[131];
|
|
519
|
+
let t60;
|
|
520
|
+
if ($[132] !== t59) {
|
|
521
|
+
t60 = /* @__PURE__ */ jsx("option", {
|
|
522
|
+
value: "offset",
|
|
523
|
+
children: t59
|
|
524
|
+
});
|
|
525
|
+
$[132] = t59;
|
|
526
|
+
$[133] = t60;
|
|
527
|
+
} else t60 = $[133];
|
|
528
|
+
let t61;
|
|
529
|
+
if ($[134] !== fieldIds.vMode || $[135] !== t58 || $[136] !== t60 || $[137] !== vMode) {
|
|
530
|
+
t61 = /* @__PURE__ */ jsxs("select", {
|
|
531
|
+
className: "border-input bg-background text-foreground flex-1 rounded border px-1.5 py-1 text-xs outline-none",
|
|
532
|
+
id: t55,
|
|
533
|
+
value: vMode,
|
|
534
|
+
onChange: t56,
|
|
535
|
+
children: [t58, t60]
|
|
536
|
+
});
|
|
537
|
+
$[134] = fieldIds.vMode;
|
|
538
|
+
$[135] = t58;
|
|
539
|
+
$[136] = t60;
|
|
540
|
+
$[137] = vMode;
|
|
541
|
+
$[138] = t61;
|
|
542
|
+
} else t61 = $[138];
|
|
543
|
+
let t62;
|
|
544
|
+
if ($[139] !== t54 || $[140] !== t61) {
|
|
545
|
+
t62 = /* @__PURE__ */ jsxs("div", {
|
|
546
|
+
className: "flex items-center gap-2",
|
|
547
|
+
children: [t54, t61]
|
|
548
|
+
});
|
|
549
|
+
$[139] = t54;
|
|
550
|
+
$[140] = t61;
|
|
551
|
+
$[141] = t62;
|
|
552
|
+
} else t62 = $[141];
|
|
553
|
+
let t63;
|
|
554
|
+
if ($[142] !== fieldIds.vAlign || $[143] !== fieldIds.vOffset || $[144] !== t || $[145] !== vAlign || $[146] !== vMode || $[147] !== vOffset) {
|
|
555
|
+
t63 = vMode === "align" ? /* @__PURE__ */ jsxs("div", {
|
|
556
|
+
className: "flex items-center gap-2",
|
|
557
|
+
children: [/* @__PURE__ */ jsx("label", {
|
|
558
|
+
className: "w-[75px] text-muted-foreground text-xs",
|
|
559
|
+
htmlFor: fieldIds.vAlign,
|
|
560
|
+
children: t("dialogs.imagePosition.align")
|
|
561
|
+
}), /* @__PURE__ */ jsxs("select", {
|
|
562
|
+
className: "border-input bg-background text-foreground flex-1 rounded border px-1.5 py-1 text-xs outline-none",
|
|
563
|
+
id: fieldIds.vAlign,
|
|
564
|
+
value: vAlign,
|
|
565
|
+
onChange: (e_4) => setVAlign(e_4.target.value),
|
|
566
|
+
children: [
|
|
567
|
+
/* @__PURE__ */ jsx("option", {
|
|
568
|
+
value: "top",
|
|
569
|
+
children: t("dialogs.imagePosition.alignOptions.top")
|
|
570
|
+
}),
|
|
571
|
+
/* @__PURE__ */ jsx("option", {
|
|
572
|
+
value: "center",
|
|
573
|
+
children: t("dialogs.imagePosition.alignOptions.center")
|
|
574
|
+
}),
|
|
575
|
+
/* @__PURE__ */ jsx("option", {
|
|
576
|
+
value: "bottom",
|
|
577
|
+
children: t("dialogs.imagePosition.alignOptions.bottom")
|
|
578
|
+
})
|
|
579
|
+
]
|
|
580
|
+
})]
|
|
581
|
+
}) : /* @__PURE__ */ jsxs("div", {
|
|
582
|
+
className: "flex items-center gap-2",
|
|
583
|
+
children: [/* @__PURE__ */ jsx("label", {
|
|
584
|
+
className: "w-[75px] text-muted-foreground text-xs",
|
|
585
|
+
htmlFor: fieldIds.vOffset,
|
|
586
|
+
children: t("dialogs.imagePosition.offsetPx")
|
|
587
|
+
}), /* @__PURE__ */ jsx("input", {
|
|
588
|
+
className: "border-input bg-background text-foreground flex-1 rounded border px-1.5 py-1 text-xs outline-none",
|
|
589
|
+
id: fieldIds.vOffset,
|
|
590
|
+
type: "number",
|
|
591
|
+
value: vOffset,
|
|
592
|
+
onChange: (e_5) => setVOffset(Number(e_5.target.value) || 0)
|
|
593
|
+
})]
|
|
594
|
+
});
|
|
595
|
+
$[142] = fieldIds.vAlign;
|
|
596
|
+
$[143] = fieldIds.vOffset;
|
|
597
|
+
$[144] = t;
|
|
598
|
+
$[145] = vAlign;
|
|
599
|
+
$[146] = vMode;
|
|
600
|
+
$[147] = vOffset;
|
|
601
|
+
$[148] = t63;
|
|
602
|
+
} else t63 = $[148];
|
|
603
|
+
const t64 = fieldIds.vRelativeTo;
|
|
604
|
+
let t65;
|
|
605
|
+
if ($[149] !== t) {
|
|
606
|
+
t65 = t("dialogs.imagePosition.relativeTo");
|
|
607
|
+
$[149] = t;
|
|
608
|
+
$[150] = t65;
|
|
609
|
+
} else t65 = $[150];
|
|
610
|
+
let t66;
|
|
611
|
+
if ($[151] !== fieldIds.vRelativeTo || $[152] !== t65) {
|
|
612
|
+
t66 = /* @__PURE__ */ jsx("label", {
|
|
613
|
+
className: "w-[75px] text-muted-foreground text-xs",
|
|
614
|
+
htmlFor: t64,
|
|
615
|
+
children: t65
|
|
616
|
+
});
|
|
617
|
+
$[151] = fieldIds.vRelativeTo;
|
|
618
|
+
$[152] = t65;
|
|
619
|
+
$[153] = t66;
|
|
620
|
+
} else t66 = $[153];
|
|
621
|
+
const t67 = fieldIds.vRelativeTo;
|
|
622
|
+
let t68;
|
|
623
|
+
if ($[154] === Symbol.for("react.memo_cache_sentinel")) {
|
|
624
|
+
t68 = (e_6) => setVRelativeTo(e_6.target.value);
|
|
625
|
+
$[154] = t68;
|
|
626
|
+
} else t68 = $[154];
|
|
627
|
+
let t69;
|
|
628
|
+
if ($[155] !== t) {
|
|
629
|
+
t69 = t("dialogs.imagePosition.relativeOptions.page");
|
|
630
|
+
$[155] = t;
|
|
631
|
+
$[156] = t69;
|
|
632
|
+
} else t69 = $[156];
|
|
633
|
+
let t70;
|
|
634
|
+
if ($[157] !== t69) {
|
|
635
|
+
t70 = /* @__PURE__ */ jsx("option", {
|
|
636
|
+
value: "page",
|
|
637
|
+
children: t69
|
|
638
|
+
});
|
|
639
|
+
$[157] = t69;
|
|
640
|
+
$[158] = t70;
|
|
641
|
+
} else t70 = $[158];
|
|
642
|
+
let t71;
|
|
643
|
+
if ($[159] !== t) {
|
|
644
|
+
t71 = t("dialogs.imagePosition.relativeOptions.margin");
|
|
645
|
+
$[159] = t;
|
|
646
|
+
$[160] = t71;
|
|
647
|
+
} else t71 = $[160];
|
|
648
|
+
let t72;
|
|
649
|
+
if ($[161] !== t71) {
|
|
650
|
+
t72 = /* @__PURE__ */ jsx("option", {
|
|
651
|
+
value: "margin",
|
|
652
|
+
children: t71
|
|
653
|
+
});
|
|
654
|
+
$[161] = t71;
|
|
655
|
+
$[162] = t72;
|
|
656
|
+
} else t72 = $[162];
|
|
657
|
+
let t73;
|
|
658
|
+
if ($[163] !== t) {
|
|
659
|
+
t73 = t("dialogs.imagePosition.relativeOptions.paragraph");
|
|
660
|
+
$[163] = t;
|
|
661
|
+
$[164] = t73;
|
|
662
|
+
} else t73 = $[164];
|
|
663
|
+
let t74;
|
|
664
|
+
if ($[165] !== t73) {
|
|
665
|
+
t74 = /* @__PURE__ */ jsx("option", {
|
|
666
|
+
value: "paragraph",
|
|
667
|
+
children: t73
|
|
668
|
+
});
|
|
669
|
+
$[165] = t73;
|
|
670
|
+
$[166] = t74;
|
|
671
|
+
} else t74 = $[166];
|
|
672
|
+
let t75;
|
|
673
|
+
if ($[167] !== t) {
|
|
674
|
+
t75 = t("dialogs.imagePosition.relativeOptions.line");
|
|
675
|
+
$[167] = t;
|
|
676
|
+
$[168] = t75;
|
|
677
|
+
} else t75 = $[168];
|
|
678
|
+
let t76;
|
|
679
|
+
if ($[169] !== t75) {
|
|
680
|
+
t76 = /* @__PURE__ */ jsx("option", {
|
|
681
|
+
value: "line",
|
|
682
|
+
children: t75
|
|
683
|
+
});
|
|
684
|
+
$[169] = t75;
|
|
685
|
+
$[170] = t76;
|
|
686
|
+
} else t76 = $[170];
|
|
687
|
+
let t77;
|
|
688
|
+
if ($[171] !== fieldIds.vRelativeTo || $[172] !== t70 || $[173] !== t72 || $[174] !== t74 || $[175] !== t76 || $[176] !== vRelativeTo) {
|
|
689
|
+
t77 = /* @__PURE__ */ jsxs("select", {
|
|
690
|
+
className: "border-input bg-background text-foreground flex-1 rounded border px-1.5 py-1 text-xs outline-none",
|
|
691
|
+
id: t67,
|
|
692
|
+
value: vRelativeTo,
|
|
693
|
+
onChange: t68,
|
|
694
|
+
children: [
|
|
695
|
+
t70,
|
|
696
|
+
t72,
|
|
697
|
+
t74,
|
|
698
|
+
t76
|
|
699
|
+
]
|
|
700
|
+
});
|
|
701
|
+
$[171] = fieldIds.vRelativeTo;
|
|
702
|
+
$[172] = t70;
|
|
703
|
+
$[173] = t72;
|
|
704
|
+
$[174] = t74;
|
|
705
|
+
$[175] = t76;
|
|
706
|
+
$[176] = vRelativeTo;
|
|
707
|
+
$[177] = t77;
|
|
708
|
+
} else t77 = $[177];
|
|
709
|
+
let t78;
|
|
710
|
+
if ($[178] !== t66 || $[179] !== t77) {
|
|
711
|
+
t78 = /* @__PURE__ */ jsxs("div", {
|
|
712
|
+
className: "flex items-center gap-2",
|
|
713
|
+
children: [t66, t77]
|
|
714
|
+
});
|
|
715
|
+
$[178] = t66;
|
|
716
|
+
$[179] = t77;
|
|
717
|
+
$[180] = t78;
|
|
718
|
+
} else t78 = $[180];
|
|
719
|
+
let t79;
|
|
720
|
+
if ($[181] !== t51 || $[182] !== t62 || $[183] !== t63 || $[184] !== t78) {
|
|
721
|
+
t79 = /* @__PURE__ */ jsxs("div", {
|
|
722
|
+
className: "flex flex-col gap-2",
|
|
723
|
+
children: [
|
|
724
|
+
t51,
|
|
725
|
+
t62,
|
|
726
|
+
t63,
|
|
727
|
+
t78
|
|
728
|
+
]
|
|
729
|
+
});
|
|
730
|
+
$[181] = t51;
|
|
731
|
+
$[182] = t62;
|
|
732
|
+
$[183] = t63;
|
|
733
|
+
$[184] = t78;
|
|
734
|
+
$[185] = t79;
|
|
735
|
+
} else t79 = $[185];
|
|
736
|
+
let t80;
|
|
737
|
+
if ($[186] !== t) {
|
|
738
|
+
t80 = t("dialogs.imagePosition.distanceFromText");
|
|
739
|
+
$[186] = t;
|
|
740
|
+
$[187] = t80;
|
|
741
|
+
} else t80 = $[187];
|
|
742
|
+
let t81;
|
|
743
|
+
if ($[188] !== t80) {
|
|
744
|
+
t81 = /* @__PURE__ */ jsx("div", {
|
|
745
|
+
className: "text-foreground text-[13px] font-semibold",
|
|
746
|
+
children: t80
|
|
747
|
+
});
|
|
748
|
+
$[188] = t80;
|
|
749
|
+
$[189] = t81;
|
|
750
|
+
} else t81 = $[189];
|
|
751
|
+
const t82 = fieldIds.distTop;
|
|
752
|
+
let t83;
|
|
753
|
+
if ($[190] !== t) {
|
|
754
|
+
t83 = t("dialogs.imagePosition.alignOptions.top");
|
|
755
|
+
$[190] = t;
|
|
756
|
+
$[191] = t83;
|
|
757
|
+
} else t83 = $[191];
|
|
758
|
+
let t84;
|
|
759
|
+
if ($[192] !== fieldIds.distTop || $[193] !== t83) {
|
|
760
|
+
t84 = /* @__PURE__ */ jsx("label", {
|
|
761
|
+
className: "w-[45px] text-muted-foreground text-xs",
|
|
762
|
+
htmlFor: t82,
|
|
763
|
+
children: t83
|
|
764
|
+
});
|
|
765
|
+
$[192] = fieldIds.distTop;
|
|
766
|
+
$[193] = t83;
|
|
767
|
+
$[194] = t84;
|
|
768
|
+
} else t84 = $[194];
|
|
769
|
+
let t85;
|
|
770
|
+
if ($[195] === Symbol.for("react.memo_cache_sentinel")) {
|
|
771
|
+
t85 = (e_7) => setDistTop(Number(e_7.target.value) || 0);
|
|
772
|
+
$[195] = t85;
|
|
773
|
+
} else t85 = $[195];
|
|
774
|
+
let t86;
|
|
775
|
+
if ($[196] !== distTop || $[197] !== fieldIds.distTop) {
|
|
776
|
+
t86 = /* @__PURE__ */ jsx("input", {
|
|
777
|
+
className: "border-input bg-background text-foreground flex-1 rounded border px-1.5 py-1 text-xs outline-none",
|
|
778
|
+
id: fieldIds.distTop,
|
|
779
|
+
min: 0,
|
|
780
|
+
type: "number",
|
|
781
|
+
value: distTop,
|
|
782
|
+
onChange: t85
|
|
783
|
+
});
|
|
784
|
+
$[196] = distTop;
|
|
785
|
+
$[197] = fieldIds.distTop;
|
|
786
|
+
$[198] = t86;
|
|
787
|
+
} else t86 = $[198];
|
|
788
|
+
let t87;
|
|
789
|
+
if ($[199] !== t84 || $[200] !== t86) {
|
|
790
|
+
t87 = /* @__PURE__ */ jsxs("div", {
|
|
791
|
+
className: "flex items-center gap-2",
|
|
792
|
+
children: [t84, t86]
|
|
793
|
+
});
|
|
794
|
+
$[199] = t84;
|
|
795
|
+
$[200] = t86;
|
|
796
|
+
$[201] = t87;
|
|
797
|
+
} else t87 = $[201];
|
|
798
|
+
const t88 = fieldIds.distBottom;
|
|
799
|
+
let t89;
|
|
800
|
+
if ($[202] !== t) {
|
|
801
|
+
t89 = t("dialogs.imagePosition.alignOptions.bottom");
|
|
802
|
+
$[202] = t;
|
|
803
|
+
$[203] = t89;
|
|
804
|
+
} else t89 = $[203];
|
|
805
|
+
let t90;
|
|
806
|
+
if ($[204] !== fieldIds.distBottom || $[205] !== t89) {
|
|
807
|
+
t90 = /* @__PURE__ */ jsx("label", {
|
|
808
|
+
className: "w-[45px] text-muted-foreground text-xs",
|
|
809
|
+
htmlFor: t88,
|
|
810
|
+
children: t89
|
|
811
|
+
});
|
|
812
|
+
$[204] = fieldIds.distBottom;
|
|
813
|
+
$[205] = t89;
|
|
814
|
+
$[206] = t90;
|
|
815
|
+
} else t90 = $[206];
|
|
816
|
+
let t91;
|
|
817
|
+
if ($[207] === Symbol.for("react.memo_cache_sentinel")) {
|
|
818
|
+
t91 = (e_8) => setDistBottom(Number(e_8.target.value) || 0);
|
|
819
|
+
$[207] = t91;
|
|
820
|
+
} else t91 = $[207];
|
|
821
|
+
let t92;
|
|
822
|
+
if ($[208] !== distBottom || $[209] !== fieldIds.distBottom) {
|
|
823
|
+
t92 = /* @__PURE__ */ jsx("input", {
|
|
824
|
+
className: "border-input bg-background text-foreground flex-1 rounded border px-1.5 py-1 text-xs outline-none",
|
|
825
|
+
id: fieldIds.distBottom,
|
|
826
|
+
min: 0,
|
|
827
|
+
type: "number",
|
|
828
|
+
value: distBottom,
|
|
829
|
+
onChange: t91
|
|
830
|
+
});
|
|
831
|
+
$[208] = distBottom;
|
|
832
|
+
$[209] = fieldIds.distBottom;
|
|
833
|
+
$[210] = t92;
|
|
834
|
+
} else t92 = $[210];
|
|
835
|
+
let t93;
|
|
836
|
+
if ($[211] !== t90 || $[212] !== t92) {
|
|
837
|
+
t93 = /* @__PURE__ */ jsxs("div", {
|
|
838
|
+
className: "flex items-center gap-2",
|
|
839
|
+
children: [t90, t92]
|
|
840
|
+
});
|
|
841
|
+
$[211] = t90;
|
|
842
|
+
$[212] = t92;
|
|
843
|
+
$[213] = t93;
|
|
844
|
+
} else t93 = $[213];
|
|
845
|
+
const t94 = fieldIds.distLeft;
|
|
846
|
+
let t95;
|
|
847
|
+
if ($[214] !== t) {
|
|
848
|
+
t95 = t("dialogs.imagePosition.alignOptions.left");
|
|
849
|
+
$[214] = t;
|
|
850
|
+
$[215] = t95;
|
|
851
|
+
} else t95 = $[215];
|
|
852
|
+
let t96;
|
|
853
|
+
if ($[216] !== fieldIds.distLeft || $[217] !== t95) {
|
|
854
|
+
t96 = /* @__PURE__ */ jsx("label", {
|
|
855
|
+
className: "w-[45px] text-muted-foreground text-xs",
|
|
856
|
+
htmlFor: t94,
|
|
857
|
+
children: t95
|
|
858
|
+
});
|
|
859
|
+
$[216] = fieldIds.distLeft;
|
|
860
|
+
$[217] = t95;
|
|
861
|
+
$[218] = t96;
|
|
862
|
+
} else t96 = $[218];
|
|
863
|
+
let t97;
|
|
864
|
+
if ($[219] === Symbol.for("react.memo_cache_sentinel")) {
|
|
865
|
+
t97 = (e_9) => setDistLeft(Number(e_9.target.value) || 0);
|
|
866
|
+
$[219] = t97;
|
|
867
|
+
} else t97 = $[219];
|
|
868
|
+
let t98;
|
|
869
|
+
if ($[220] !== distLeft || $[221] !== fieldIds.distLeft) {
|
|
870
|
+
t98 = /* @__PURE__ */ jsx("input", {
|
|
871
|
+
className: "border-input bg-background text-foreground flex-1 rounded border px-1.5 py-1 text-xs outline-none",
|
|
872
|
+
id: fieldIds.distLeft,
|
|
873
|
+
min: 0,
|
|
874
|
+
type: "number",
|
|
875
|
+
value: distLeft,
|
|
876
|
+
onChange: t97
|
|
877
|
+
});
|
|
878
|
+
$[220] = distLeft;
|
|
879
|
+
$[221] = fieldIds.distLeft;
|
|
880
|
+
$[222] = t98;
|
|
881
|
+
} else t98 = $[222];
|
|
882
|
+
let t99;
|
|
883
|
+
if ($[223] !== t96 || $[224] !== t98) {
|
|
884
|
+
t99 = /* @__PURE__ */ jsxs("div", {
|
|
885
|
+
className: "flex items-center gap-2",
|
|
886
|
+
children: [t96, t98]
|
|
887
|
+
});
|
|
888
|
+
$[223] = t96;
|
|
889
|
+
$[224] = t98;
|
|
890
|
+
$[225] = t99;
|
|
891
|
+
} else t99 = $[225];
|
|
892
|
+
const t100 = fieldIds.distRight;
|
|
893
|
+
let t101;
|
|
894
|
+
if ($[226] !== t) {
|
|
895
|
+
t101 = t("dialogs.imagePosition.alignOptions.right");
|
|
896
|
+
$[226] = t;
|
|
897
|
+
$[227] = t101;
|
|
898
|
+
} else t101 = $[227];
|
|
899
|
+
let t102;
|
|
900
|
+
if ($[228] !== fieldIds.distRight || $[229] !== t101) {
|
|
901
|
+
t102 = /* @__PURE__ */ jsx("label", {
|
|
902
|
+
className: "w-[45px] text-muted-foreground text-xs",
|
|
903
|
+
htmlFor: t100,
|
|
904
|
+
children: t101
|
|
905
|
+
});
|
|
906
|
+
$[228] = fieldIds.distRight;
|
|
907
|
+
$[229] = t101;
|
|
908
|
+
$[230] = t102;
|
|
909
|
+
} else t102 = $[230];
|
|
910
|
+
let t103;
|
|
911
|
+
if ($[231] === Symbol.for("react.memo_cache_sentinel")) {
|
|
912
|
+
t103 = (e_10) => setDistRight(Number(e_10.target.value) || 0);
|
|
913
|
+
$[231] = t103;
|
|
914
|
+
} else t103 = $[231];
|
|
915
|
+
let t104;
|
|
916
|
+
if ($[232] !== distRight || $[233] !== fieldIds.distRight) {
|
|
917
|
+
t104 = /* @__PURE__ */ jsx("input", {
|
|
918
|
+
className: "border-input bg-background text-foreground flex-1 rounded border px-1.5 py-1 text-xs outline-none",
|
|
919
|
+
id: fieldIds.distRight,
|
|
920
|
+
min: 0,
|
|
921
|
+
type: "number",
|
|
922
|
+
value: distRight,
|
|
923
|
+
onChange: t103
|
|
924
|
+
});
|
|
925
|
+
$[232] = distRight;
|
|
926
|
+
$[233] = fieldIds.distRight;
|
|
927
|
+
$[234] = t104;
|
|
928
|
+
} else t104 = $[234];
|
|
929
|
+
let t105;
|
|
930
|
+
if ($[235] !== t102 || $[236] !== t104) {
|
|
931
|
+
t105 = /* @__PURE__ */ jsxs("div", {
|
|
932
|
+
className: "flex items-center gap-2",
|
|
933
|
+
children: [t102, t104]
|
|
934
|
+
});
|
|
935
|
+
$[235] = t102;
|
|
936
|
+
$[236] = t104;
|
|
937
|
+
$[237] = t105;
|
|
938
|
+
} else t105 = $[237];
|
|
939
|
+
let t106;
|
|
940
|
+
if ($[238] !== t105 || $[239] !== t87 || $[240] !== t93 || $[241] !== t99) {
|
|
941
|
+
t106 = /* @__PURE__ */ jsxs("div", {
|
|
942
|
+
className: "grid grid-cols-2 gap-2",
|
|
943
|
+
children: [
|
|
944
|
+
t87,
|
|
945
|
+
t93,
|
|
946
|
+
t99,
|
|
947
|
+
t105
|
|
948
|
+
]
|
|
949
|
+
});
|
|
950
|
+
$[238] = t105;
|
|
951
|
+
$[239] = t87;
|
|
952
|
+
$[240] = t93;
|
|
953
|
+
$[241] = t99;
|
|
954
|
+
$[242] = t106;
|
|
955
|
+
} else t106 = $[242];
|
|
956
|
+
let t107;
|
|
957
|
+
if ($[243] !== t106 || $[244] !== t81) {
|
|
958
|
+
t107 = /* @__PURE__ */ jsxs("div", {
|
|
959
|
+
className: "flex flex-col gap-2",
|
|
960
|
+
children: [t81, t106]
|
|
961
|
+
});
|
|
962
|
+
$[243] = t106;
|
|
963
|
+
$[244] = t81;
|
|
964
|
+
$[245] = t107;
|
|
965
|
+
} else t107 = $[245];
|
|
966
|
+
let t108;
|
|
967
|
+
if ($[246] !== t107 || $[247] !== t49 || $[248] !== t79) {
|
|
968
|
+
t108 = /* @__PURE__ */ jsxs("div", {
|
|
969
|
+
className: "flex flex-col gap-4 px-5 py-4",
|
|
970
|
+
children: [
|
|
971
|
+
t49,
|
|
972
|
+
t79,
|
|
973
|
+
t107
|
|
974
|
+
]
|
|
975
|
+
});
|
|
976
|
+
$[246] = t107;
|
|
977
|
+
$[247] = t49;
|
|
978
|
+
$[248] = t79;
|
|
979
|
+
$[249] = t108;
|
|
980
|
+
} else t108 = $[249];
|
|
981
|
+
let t109;
|
|
982
|
+
if ($[250] !== t) {
|
|
983
|
+
t109 = t("common.cancel");
|
|
984
|
+
$[250] = t;
|
|
985
|
+
$[251] = t109;
|
|
986
|
+
} else t109 = $[251];
|
|
987
|
+
let t110;
|
|
988
|
+
if ($[252] !== DialogClose || $[253] !== t109) {
|
|
989
|
+
t110 = /* @__PURE__ */ jsx(DialogClose, {
|
|
990
|
+
className: "border-input rounded border px-4 py-1.5 text-[13px]",
|
|
991
|
+
children: t109
|
|
992
|
+
});
|
|
993
|
+
$[252] = DialogClose;
|
|
994
|
+
$[253] = t109;
|
|
995
|
+
$[254] = t110;
|
|
996
|
+
} else t110 = $[254];
|
|
997
|
+
let t111;
|
|
998
|
+
if ($[255] !== t) {
|
|
999
|
+
t111 = t("common.apply");
|
|
1000
|
+
$[255] = t;
|
|
1001
|
+
$[256] = t111;
|
|
1002
|
+
} else t111 = $[256];
|
|
1003
|
+
let t112;
|
|
1004
|
+
if ($[257] !== handleApply || $[258] !== t111) {
|
|
1005
|
+
t112 = /* @__PURE__ */ jsx("button", {
|
|
1006
|
+
className: "bg-primary text-primary-foreground rounded px-4 py-1.5 text-[13px] font-medium",
|
|
1007
|
+
onClick: handleApply,
|
|
1008
|
+
type: "button",
|
|
1009
|
+
children: t111
|
|
1010
|
+
});
|
|
1011
|
+
$[257] = handleApply;
|
|
1012
|
+
$[258] = t111;
|
|
1013
|
+
$[259] = t112;
|
|
1014
|
+
} else t112 = $[259];
|
|
1015
|
+
let t113;
|
|
1016
|
+
if ($[260] !== t110 || $[261] !== t112) {
|
|
1017
|
+
t113 = /* @__PURE__ */ jsxs("div", {
|
|
1018
|
+
className: "flex justify-end gap-2 border-t px-5 py-3",
|
|
1019
|
+
children: [t110, t112]
|
|
1020
|
+
});
|
|
1021
|
+
$[260] = t110;
|
|
1022
|
+
$[261] = t112;
|
|
1023
|
+
$[262] = t113;
|
|
1024
|
+
} else t113 = $[262];
|
|
1025
|
+
let t114;
|
|
1026
|
+
if ($[263] !== DialogPopup || $[264] !== t108 || $[265] !== t113 || $[266] !== t19) {
|
|
1027
|
+
t114 = /* @__PURE__ */ jsxs(DialogPopup, {
|
|
1028
|
+
className: "bg-popover fixed start-1/2 top-1/2 z-[10001] w-full max-w-[480px] min-w-[400px] -translate-x-1/2 -translate-y-1/2 rounded-lg border shadow-xl",
|
|
1029
|
+
children: [
|
|
1030
|
+
t19,
|
|
1031
|
+
t108,
|
|
1032
|
+
t113
|
|
1033
|
+
]
|
|
1034
|
+
});
|
|
1035
|
+
$[263] = DialogPopup;
|
|
1036
|
+
$[264] = t108;
|
|
1037
|
+
$[265] = t113;
|
|
1038
|
+
$[266] = t19;
|
|
1039
|
+
$[267] = t114;
|
|
1040
|
+
} else t114 = $[267];
|
|
1041
|
+
let t115;
|
|
1042
|
+
if ($[268] !== DialogPortal || $[269] !== t114 || $[270] !== t17) {
|
|
1043
|
+
t115 = /* @__PURE__ */ jsxs(DialogPortal, { children: [t17, t114] });
|
|
1044
|
+
$[268] = DialogPortal;
|
|
1045
|
+
$[269] = t114;
|
|
1046
|
+
$[270] = t17;
|
|
1047
|
+
$[271] = t115;
|
|
1048
|
+
} else t115 = $[271];
|
|
1049
|
+
let t116;
|
|
1050
|
+
if ($[272] !== Dialog || $[273] !== handleOpenChange || $[274] !== isOpen || $[275] !== t115) {
|
|
1051
|
+
t116 = /* @__PURE__ */ jsx(Dialog, {
|
|
1052
|
+
open: isOpen,
|
|
1053
|
+
onOpenChange: handleOpenChange,
|
|
1054
|
+
children: t115
|
|
1055
|
+
});
|
|
1056
|
+
$[272] = Dialog;
|
|
1057
|
+
$[273] = handleOpenChange;
|
|
1058
|
+
$[274] = isOpen;
|
|
1059
|
+
$[275] = t115;
|
|
1060
|
+
$[276] = t116;
|
|
1061
|
+
} else t116 = $[276];
|
|
1062
|
+
return t116;
|
|
1063
|
+
}
|
|
1064
|
+
//#endregion
|
|
1065
|
+
export { ImagePositionDialog_exports as n, ImagePositionDialog as t };
|