@stll/folio-react 0.7.0 → 0.8.1
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-B8X5a8JW.js → CommentsSidebar-Byn5lyrt.js} +2 -2
- package/dist/{FindReplaceDialog-Bx7QaFQ_.js → FindReplaceDialog-CqKK82nE.js} +1 -1
- package/dist/FootnotePropertiesDialog-CixRdIiT.js +822 -0
- package/dist/ImagePositionDialog-DNodkoI2.js +1065 -0
- package/dist/ImagePropertiesDialog-CLsDIUWb.js +613 -0
- package/dist/{InsertSymbolDialog-Df9dyLvn.js → InsertSymbolDialog-DCFLmfzn.js} +1 -1
- package/dist/PageSetupDialog-COkgeOQn.js +820 -0
- package/dist/TablePropertiesDialog-B_AGrPR8.js +434 -0
- package/dist/compat/eigenpal.d.ts +1 -1
- package/dist/compat/eigenpal.js +1 -1
- package/dist/{dialogs-DsHnfN0g.js → dialogs-Bj2PdycR.js} +265 -201
- package/dist/dialogs.js +8 -8
- package/dist/{folio-ui-C-85DSuK.js → folio-ui-BgDDRsUX.js} +5 -3
- package/dist/index.d.ts +1 -1
- package/dist/index.js +10 -10
- package/dist/{renderAsync-ChQI9UJG.d.ts → renderAsync-BmxQE7iO.d.ts} +3 -2
- package/dist/{renderAsync-evdyE_GW.js → renderAsync-BtWYvQMT.js} +378 -273
- package/package.json +2 -2
- package/dist/FootnotePropertiesDialog-2lmpg9m8.js +0 -646
- package/dist/ImagePositionDialog-D3MileYL.js +0 -842
- package/dist/ImagePropertiesDialog-CzK8HCaW.js +0 -465
- package/dist/PageSetupDialog-PSs9YdPb.js +0 -684
- package/dist/TablePropertiesDialog-PQxKKM0Y.js +0 -344
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stll/folio-react",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.8.1",
|
|
4
4
|
"description": "React editor for folio: a Word-document (.docx) editor for the browser, built on @stll/folio-core and ProseMirror.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"document-editor",
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
"@fontsource/noto-sans-arabic": "^5.2.7",
|
|
68
68
|
"@fontsource/source-sans-3": "^5.2.9",
|
|
69
69
|
"@fontsource/tinos": "^5.2.7",
|
|
70
|
-
"@stll/folio-core": "^0.
|
|
70
|
+
"@stll/folio-core": "^0.6.0",
|
|
71
71
|
"better-result": "2.9.2",
|
|
72
72
|
"lucide-react": "1.24.0",
|
|
73
73
|
"prosemirror-history": "^1.5.0",
|
|
@@ -1,646 +0,0 @@
|
|
|
1
|
-
import { t as __exportAll } from "./rolldown-runtime-BBjsoOtd.js";
|
|
2
|
-
import { r as useFolioUI } from "./folio-ui-C-85DSuK.js";
|
|
3
|
-
import { u as useCloseOnDialogOpenChange } from "./dialogChrome-BoGYPgeu.js";
|
|
4
|
-
import { c } from "react-compiler-runtime";
|
|
5
|
-
import { useId, useState } from "react";
|
|
6
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
|
-
//#region src/components/dialogs/FootnotePropertiesDialog.tsx
|
|
8
|
-
/**
|
|
9
|
-
* Footnote & Endnote Properties Dialog
|
|
10
|
-
*
|
|
11
|
-
* Edits position, numbering format, start number, and restart rules.
|
|
12
|
-
*/
|
|
13
|
-
var FootnotePropertiesDialog_exports = /* @__PURE__ */ __exportAll({ FootnotePropertiesDialog: () => FootnotePropertiesDialog });
|
|
14
|
-
const numberFormatOptions = [
|
|
15
|
-
{
|
|
16
|
-
value: "decimal",
|
|
17
|
-
label: "1, 2, 3, ..."
|
|
18
|
-
},
|
|
19
|
-
{
|
|
20
|
-
value: "lowerRoman",
|
|
21
|
-
label: "i, ii, iii, ..."
|
|
22
|
-
},
|
|
23
|
-
{
|
|
24
|
-
value: "upperRoman",
|
|
25
|
-
label: "I, II, III, ..."
|
|
26
|
-
},
|
|
27
|
-
{
|
|
28
|
-
value: "lowerLetter",
|
|
29
|
-
label: "a, b, c, ..."
|
|
30
|
-
},
|
|
31
|
-
{
|
|
32
|
-
value: "upperLetter",
|
|
33
|
-
label: "A, B, C, ..."
|
|
34
|
-
},
|
|
35
|
-
{
|
|
36
|
-
value: "chicago",
|
|
37
|
-
label: "*, †, ‡, ..."
|
|
38
|
-
}
|
|
39
|
-
];
|
|
40
|
-
function FootnotePropertiesDialog(t0) {
|
|
41
|
-
const $ = c(139);
|
|
42
|
-
const { isOpen, onClose, onApply, footnotePr, endnotePr } = t0;
|
|
43
|
-
const { Root: Dialog, Portal: DialogPortal, Backdrop: DialogBackdrop, Popup: DialogPopup, Title: DialogTitle, Close: DialogClose } = useFolioUI().Dialog;
|
|
44
|
-
const handleOpenChange = useCloseOnDialogOpenChange(onClose);
|
|
45
|
-
const id = useId();
|
|
46
|
-
const [fnPosition, setFnPosition] = useState(footnotePr?.position ?? "pageBottom");
|
|
47
|
-
const [fnNumFmt, setFnNumFmt] = useState(footnotePr?.numFmt ?? "decimal");
|
|
48
|
-
const [fnNumStart, setFnNumStart] = useState(footnotePr?.numStart ?? 1);
|
|
49
|
-
const [fnRestart, setFnRestart] = useState(footnotePr?.numRestart ?? "continuous");
|
|
50
|
-
const [enPosition, setEnPosition] = useState(endnotePr?.position ?? "docEnd");
|
|
51
|
-
const [enNumFmt, setEnNumFmt] = useState(endnotePr?.numFmt ?? "lowerRoman");
|
|
52
|
-
const [enNumStart, setEnNumStart] = useState(endnotePr?.numStart ?? 1);
|
|
53
|
-
const [enRestart, setEnRestart] = useState(endnotePr?.numRestart ?? "continuous");
|
|
54
|
-
let t1;
|
|
55
|
-
if ($[0] !== enNumFmt || $[1] !== enNumStart || $[2] !== enPosition || $[3] !== enRestart || $[4] !== fnNumFmt || $[5] !== fnNumStart || $[6] !== fnPosition || $[7] !== fnRestart || $[8] !== onApply || $[9] !== onClose) {
|
|
56
|
-
t1 = () => {
|
|
57
|
-
onApply({
|
|
58
|
-
position: fnPosition,
|
|
59
|
-
numFmt: fnNumFmt,
|
|
60
|
-
numStart: fnNumStart,
|
|
61
|
-
numRestart: fnRestart
|
|
62
|
-
}, {
|
|
63
|
-
position: enPosition,
|
|
64
|
-
numFmt: enNumFmt,
|
|
65
|
-
numStart: enNumStart,
|
|
66
|
-
numRestart: enRestart
|
|
67
|
-
});
|
|
68
|
-
onClose();
|
|
69
|
-
};
|
|
70
|
-
$[0] = enNumFmt;
|
|
71
|
-
$[1] = enNumStart;
|
|
72
|
-
$[2] = enPosition;
|
|
73
|
-
$[3] = enRestart;
|
|
74
|
-
$[4] = fnNumFmt;
|
|
75
|
-
$[5] = fnNumStart;
|
|
76
|
-
$[6] = fnPosition;
|
|
77
|
-
$[7] = fnRestart;
|
|
78
|
-
$[8] = onApply;
|
|
79
|
-
$[9] = onClose;
|
|
80
|
-
$[10] = t1;
|
|
81
|
-
} else t1 = $[10];
|
|
82
|
-
const handleApply = t1;
|
|
83
|
-
const t2 = `${id}-fn-position`;
|
|
84
|
-
const t3 = `${id}-fn-num-fmt`;
|
|
85
|
-
const t4 = `${id}-fn-start-at`;
|
|
86
|
-
const t5 = `${id}-fn-numbering`;
|
|
87
|
-
const t6 = `${id}-en-position`;
|
|
88
|
-
const t7 = `${id}-en-num-fmt`;
|
|
89
|
-
const t8 = `${id}-en-start-at`;
|
|
90
|
-
const t9 = `${id}-en-numbering`;
|
|
91
|
-
let t10;
|
|
92
|
-
if ($[11] !== t2 || $[12] !== t3 || $[13] !== t4 || $[14] !== t5 || $[15] !== t6 || $[16] !== t7 || $[17] !== t8 || $[18] !== t9) {
|
|
93
|
-
t10 = {
|
|
94
|
-
fnPosition: t2,
|
|
95
|
-
fnNumFmt: t3,
|
|
96
|
-
fnStartAt: t4,
|
|
97
|
-
fnNumbering: t5,
|
|
98
|
-
enPosition: t6,
|
|
99
|
-
enNumFmt: t7,
|
|
100
|
-
enStartAt: t8,
|
|
101
|
-
enNumbering: t9
|
|
102
|
-
};
|
|
103
|
-
$[11] = t2;
|
|
104
|
-
$[12] = t3;
|
|
105
|
-
$[13] = t4;
|
|
106
|
-
$[14] = t5;
|
|
107
|
-
$[15] = t6;
|
|
108
|
-
$[16] = t7;
|
|
109
|
-
$[17] = t8;
|
|
110
|
-
$[18] = t9;
|
|
111
|
-
$[19] = t10;
|
|
112
|
-
} else t10 = $[19];
|
|
113
|
-
const fieldIds = t10;
|
|
114
|
-
let t11;
|
|
115
|
-
if ($[20] !== DialogBackdrop) {
|
|
116
|
-
t11 = /* @__PURE__ */ jsx(DialogBackdrop, { className: "fixed inset-0 z-[10000] bg-black/50" });
|
|
117
|
-
$[20] = DialogBackdrop;
|
|
118
|
-
$[21] = t11;
|
|
119
|
-
} else t11 = $[21];
|
|
120
|
-
let t12;
|
|
121
|
-
if ($[22] !== DialogTitle) {
|
|
122
|
-
t12 = /* @__PURE__ */ jsx(DialogTitle, {
|
|
123
|
-
className: "border-b px-5 py-3 text-base font-semibold",
|
|
124
|
-
children: "Footnote & Endnote Properties"
|
|
125
|
-
});
|
|
126
|
-
$[22] = DialogTitle;
|
|
127
|
-
$[23] = t12;
|
|
128
|
-
} else t12 = $[23];
|
|
129
|
-
let t13;
|
|
130
|
-
if ($[24] === Symbol.for("react.memo_cache_sentinel")) {
|
|
131
|
-
t13 = /* @__PURE__ */ jsx("h4", {
|
|
132
|
-
className: "mb-2 text-sm font-semibold",
|
|
133
|
-
children: "Footnotes"
|
|
134
|
-
});
|
|
135
|
-
$[24] = t13;
|
|
136
|
-
} else t13 = $[24];
|
|
137
|
-
let t14;
|
|
138
|
-
if ($[25] !== fieldIds.fnPosition) {
|
|
139
|
-
t14 = /* @__PURE__ */ jsx("label", {
|
|
140
|
-
htmlFor: fieldIds.fnPosition,
|
|
141
|
-
className: "block text-muted-foreground mb-1 text-xs",
|
|
142
|
-
children: "Position"
|
|
143
|
-
});
|
|
144
|
-
$[25] = fieldIds.fnPosition;
|
|
145
|
-
$[26] = t14;
|
|
146
|
-
} else t14 = $[26];
|
|
147
|
-
let t15;
|
|
148
|
-
let t16;
|
|
149
|
-
let t17;
|
|
150
|
-
if ($[27] === Symbol.for("react.memo_cache_sentinel")) {
|
|
151
|
-
t15 = (e) => setFnPosition(e.target.value);
|
|
152
|
-
t16 = /* @__PURE__ */ jsx("option", {
|
|
153
|
-
value: "pageBottom",
|
|
154
|
-
children: "Bottom of page"
|
|
155
|
-
});
|
|
156
|
-
t17 = /* @__PURE__ */ jsx("option", {
|
|
157
|
-
value: "beneathText",
|
|
158
|
-
children: "Below text"
|
|
159
|
-
});
|
|
160
|
-
$[27] = t15;
|
|
161
|
-
$[28] = t16;
|
|
162
|
-
$[29] = t17;
|
|
163
|
-
} else {
|
|
164
|
-
t15 = $[27];
|
|
165
|
-
t16 = $[28];
|
|
166
|
-
t17 = $[29];
|
|
167
|
-
}
|
|
168
|
-
let t18;
|
|
169
|
-
if ($[30] !== fieldIds.fnPosition || $[31] !== fnPosition) {
|
|
170
|
-
t18 = /* @__PURE__ */ jsxs("select", {
|
|
171
|
-
id: fieldIds.fnPosition,
|
|
172
|
-
className: "border-input bg-background text-foreground mb-2 w-full rounded border px-2 py-1 text-[13px] outline-none",
|
|
173
|
-
value: fnPosition,
|
|
174
|
-
onChange: t15,
|
|
175
|
-
children: [t16, t17]
|
|
176
|
-
});
|
|
177
|
-
$[30] = fieldIds.fnPosition;
|
|
178
|
-
$[31] = fnPosition;
|
|
179
|
-
$[32] = t18;
|
|
180
|
-
} else t18 = $[32];
|
|
181
|
-
let t19;
|
|
182
|
-
if ($[33] !== fieldIds.fnNumFmt) {
|
|
183
|
-
t19 = /* @__PURE__ */ jsx("label", {
|
|
184
|
-
htmlFor: fieldIds.fnNumFmt,
|
|
185
|
-
className: "block text-muted-foreground mb-1 text-xs",
|
|
186
|
-
children: "Number format"
|
|
187
|
-
});
|
|
188
|
-
$[33] = fieldIds.fnNumFmt;
|
|
189
|
-
$[34] = t19;
|
|
190
|
-
} else t19 = $[34];
|
|
191
|
-
const t20 = fieldIds.fnNumFmt;
|
|
192
|
-
let t21;
|
|
193
|
-
let t22;
|
|
194
|
-
if ($[35] === Symbol.for("react.memo_cache_sentinel")) {
|
|
195
|
-
t21 = (e_0) => setFnNumFmt(e_0.target.value);
|
|
196
|
-
t22 = numberFormatOptions.map(_temp);
|
|
197
|
-
$[35] = t21;
|
|
198
|
-
$[36] = t22;
|
|
199
|
-
} else {
|
|
200
|
-
t21 = $[35];
|
|
201
|
-
t22 = $[36];
|
|
202
|
-
}
|
|
203
|
-
let t23;
|
|
204
|
-
if ($[37] !== fieldIds.fnNumFmt || $[38] !== fnNumFmt) {
|
|
205
|
-
t23 = /* @__PURE__ */ jsx("select", {
|
|
206
|
-
id: t20,
|
|
207
|
-
className: "border-input bg-background text-foreground mb-2 w-full rounded border px-2 py-1 text-[13px] outline-none",
|
|
208
|
-
value: fnNumFmt,
|
|
209
|
-
onChange: t21,
|
|
210
|
-
children: t22
|
|
211
|
-
});
|
|
212
|
-
$[37] = fieldIds.fnNumFmt;
|
|
213
|
-
$[38] = fnNumFmt;
|
|
214
|
-
$[39] = t23;
|
|
215
|
-
} else t23 = $[39];
|
|
216
|
-
let t24;
|
|
217
|
-
if ($[40] !== fieldIds.fnStartAt) {
|
|
218
|
-
t24 = /* @__PURE__ */ jsx("label", {
|
|
219
|
-
htmlFor: fieldIds.fnStartAt,
|
|
220
|
-
className: "block text-muted-foreground mb-1 text-xs",
|
|
221
|
-
children: "Start at"
|
|
222
|
-
});
|
|
223
|
-
$[40] = fieldIds.fnStartAt;
|
|
224
|
-
$[41] = t24;
|
|
225
|
-
} else t24 = $[41];
|
|
226
|
-
let t25;
|
|
227
|
-
if ($[42] === Symbol.for("react.memo_cache_sentinel")) {
|
|
228
|
-
t25 = (e_1) => setFnNumStart(Number.parseInt(e_1.target.value, 10) || 1);
|
|
229
|
-
$[42] = t25;
|
|
230
|
-
} else t25 = $[42];
|
|
231
|
-
let t26;
|
|
232
|
-
if ($[43] !== fieldIds.fnStartAt || $[44] !== fnNumStart) {
|
|
233
|
-
t26 = /* @__PURE__ */ jsx("input", {
|
|
234
|
-
id: fieldIds.fnStartAt,
|
|
235
|
-
type: "number",
|
|
236
|
-
min: 1,
|
|
237
|
-
className: "border-input bg-background text-foreground w-[60px] rounded border px-2 py-1 text-[13px] outline-none",
|
|
238
|
-
value: fnNumStart,
|
|
239
|
-
onChange: t25
|
|
240
|
-
});
|
|
241
|
-
$[43] = fieldIds.fnStartAt;
|
|
242
|
-
$[44] = fnNumStart;
|
|
243
|
-
$[45] = t26;
|
|
244
|
-
} else t26 = $[45];
|
|
245
|
-
let t27;
|
|
246
|
-
if ($[46] !== t24 || $[47] !== t26) {
|
|
247
|
-
t27 = /* @__PURE__ */ jsxs("div", { children: [t24, t26] });
|
|
248
|
-
$[46] = t24;
|
|
249
|
-
$[47] = t26;
|
|
250
|
-
$[48] = t27;
|
|
251
|
-
} else t27 = $[48];
|
|
252
|
-
let t28;
|
|
253
|
-
if ($[49] !== fieldIds.fnNumbering) {
|
|
254
|
-
t28 = /* @__PURE__ */ jsx("label", {
|
|
255
|
-
htmlFor: fieldIds.fnNumbering,
|
|
256
|
-
className: "block text-muted-foreground mb-1 text-xs",
|
|
257
|
-
children: "Numbering"
|
|
258
|
-
});
|
|
259
|
-
$[49] = fieldIds.fnNumbering;
|
|
260
|
-
$[50] = t28;
|
|
261
|
-
} else t28 = $[50];
|
|
262
|
-
let t29;
|
|
263
|
-
let t30;
|
|
264
|
-
let t31;
|
|
265
|
-
let t32;
|
|
266
|
-
if ($[51] === Symbol.for("react.memo_cache_sentinel")) {
|
|
267
|
-
t29 = (e_2) => setFnRestart(e_2.target.value);
|
|
268
|
-
t30 = /* @__PURE__ */ jsx("option", {
|
|
269
|
-
value: "continuous",
|
|
270
|
-
children: "Continuous"
|
|
271
|
-
});
|
|
272
|
-
t31 = /* @__PURE__ */ jsx("option", {
|
|
273
|
-
value: "eachSect",
|
|
274
|
-
children: "Restart each section"
|
|
275
|
-
});
|
|
276
|
-
t32 = /* @__PURE__ */ jsx("option", {
|
|
277
|
-
value: "eachPage",
|
|
278
|
-
children: "Restart each page"
|
|
279
|
-
});
|
|
280
|
-
$[51] = t29;
|
|
281
|
-
$[52] = t30;
|
|
282
|
-
$[53] = t31;
|
|
283
|
-
$[54] = t32;
|
|
284
|
-
} else {
|
|
285
|
-
t29 = $[51];
|
|
286
|
-
t30 = $[52];
|
|
287
|
-
t31 = $[53];
|
|
288
|
-
t32 = $[54];
|
|
289
|
-
}
|
|
290
|
-
let t33;
|
|
291
|
-
if ($[55] !== fieldIds.fnNumbering || $[56] !== fnRestart) {
|
|
292
|
-
t33 = /* @__PURE__ */ jsxs("select", {
|
|
293
|
-
id: fieldIds.fnNumbering,
|
|
294
|
-
className: "border-input bg-background text-foreground mb-2 w-full rounded border px-2 py-1 text-[13px] outline-none",
|
|
295
|
-
value: fnRestart,
|
|
296
|
-
onChange: t29,
|
|
297
|
-
children: [
|
|
298
|
-
t30,
|
|
299
|
-
t31,
|
|
300
|
-
t32
|
|
301
|
-
]
|
|
302
|
-
});
|
|
303
|
-
$[55] = fieldIds.fnNumbering;
|
|
304
|
-
$[56] = fnRestart;
|
|
305
|
-
$[57] = t33;
|
|
306
|
-
} else t33 = $[57];
|
|
307
|
-
let t34;
|
|
308
|
-
if ($[58] !== t28 || $[59] !== t33) {
|
|
309
|
-
t34 = /* @__PURE__ */ jsxs("div", {
|
|
310
|
-
className: "flex-1",
|
|
311
|
-
children: [t28, t33]
|
|
312
|
-
});
|
|
313
|
-
$[58] = t28;
|
|
314
|
-
$[59] = t33;
|
|
315
|
-
$[60] = t34;
|
|
316
|
-
} else t34 = $[60];
|
|
317
|
-
let t35;
|
|
318
|
-
if ($[61] !== t27 || $[62] !== t34) {
|
|
319
|
-
t35 = /* @__PURE__ */ jsxs("div", {
|
|
320
|
-
className: "flex items-center gap-3",
|
|
321
|
-
children: [t27, t34]
|
|
322
|
-
});
|
|
323
|
-
$[61] = t27;
|
|
324
|
-
$[62] = t34;
|
|
325
|
-
$[63] = t35;
|
|
326
|
-
} else t35 = $[63];
|
|
327
|
-
let t36;
|
|
328
|
-
if ($[64] !== t14 || $[65] !== t18 || $[66] !== t19 || $[67] !== t23 || $[68] !== t35) {
|
|
329
|
-
t36 = /* @__PURE__ */ jsxs("div", {
|
|
330
|
-
className: "mb-4 rounded border p-3",
|
|
331
|
-
children: [
|
|
332
|
-
t13,
|
|
333
|
-
t14,
|
|
334
|
-
t18,
|
|
335
|
-
t19,
|
|
336
|
-
t23,
|
|
337
|
-
t35
|
|
338
|
-
]
|
|
339
|
-
});
|
|
340
|
-
$[64] = t14;
|
|
341
|
-
$[65] = t18;
|
|
342
|
-
$[66] = t19;
|
|
343
|
-
$[67] = t23;
|
|
344
|
-
$[68] = t35;
|
|
345
|
-
$[69] = t36;
|
|
346
|
-
} else t36 = $[69];
|
|
347
|
-
let t37;
|
|
348
|
-
if ($[70] === Symbol.for("react.memo_cache_sentinel")) {
|
|
349
|
-
t37 = /* @__PURE__ */ jsx("h4", {
|
|
350
|
-
className: "mb-2 text-sm font-semibold",
|
|
351
|
-
children: "Endnotes"
|
|
352
|
-
});
|
|
353
|
-
$[70] = t37;
|
|
354
|
-
} else t37 = $[70];
|
|
355
|
-
let t38;
|
|
356
|
-
if ($[71] !== fieldIds.enPosition) {
|
|
357
|
-
t38 = /* @__PURE__ */ jsx("label", {
|
|
358
|
-
htmlFor: fieldIds.enPosition,
|
|
359
|
-
className: "block text-muted-foreground mb-1 text-xs",
|
|
360
|
-
children: "Position"
|
|
361
|
-
});
|
|
362
|
-
$[71] = fieldIds.enPosition;
|
|
363
|
-
$[72] = t38;
|
|
364
|
-
} else t38 = $[72];
|
|
365
|
-
let t39;
|
|
366
|
-
let t40;
|
|
367
|
-
let t41;
|
|
368
|
-
if ($[73] === Symbol.for("react.memo_cache_sentinel")) {
|
|
369
|
-
t39 = (e_3) => setEnPosition(e_3.target.value);
|
|
370
|
-
t40 = /* @__PURE__ */ jsx("option", {
|
|
371
|
-
value: "docEnd",
|
|
372
|
-
children: "End of document"
|
|
373
|
-
});
|
|
374
|
-
t41 = /* @__PURE__ */ jsx("option", {
|
|
375
|
-
value: "sectEnd",
|
|
376
|
-
children: "End of section"
|
|
377
|
-
});
|
|
378
|
-
$[73] = t39;
|
|
379
|
-
$[74] = t40;
|
|
380
|
-
$[75] = t41;
|
|
381
|
-
} else {
|
|
382
|
-
t39 = $[73];
|
|
383
|
-
t40 = $[74];
|
|
384
|
-
t41 = $[75];
|
|
385
|
-
}
|
|
386
|
-
let t42;
|
|
387
|
-
if ($[76] !== enPosition || $[77] !== fieldIds.enPosition) {
|
|
388
|
-
t42 = /* @__PURE__ */ jsxs("select", {
|
|
389
|
-
id: fieldIds.enPosition,
|
|
390
|
-
className: "border-input bg-background text-foreground mb-2 w-full rounded border px-2 py-1 text-[13px] outline-none",
|
|
391
|
-
value: enPosition,
|
|
392
|
-
onChange: t39,
|
|
393
|
-
children: [t40, t41]
|
|
394
|
-
});
|
|
395
|
-
$[76] = enPosition;
|
|
396
|
-
$[77] = fieldIds.enPosition;
|
|
397
|
-
$[78] = t42;
|
|
398
|
-
} else t42 = $[78];
|
|
399
|
-
let t43;
|
|
400
|
-
if ($[79] !== fieldIds.enNumFmt) {
|
|
401
|
-
t43 = /* @__PURE__ */ jsx("label", {
|
|
402
|
-
htmlFor: fieldIds.enNumFmt,
|
|
403
|
-
className: "block text-muted-foreground mb-1 text-xs",
|
|
404
|
-
children: "Number format"
|
|
405
|
-
});
|
|
406
|
-
$[79] = fieldIds.enNumFmt;
|
|
407
|
-
$[80] = t43;
|
|
408
|
-
} else t43 = $[80];
|
|
409
|
-
const t44 = fieldIds.enNumFmt;
|
|
410
|
-
let t45;
|
|
411
|
-
let t46;
|
|
412
|
-
if ($[81] === Symbol.for("react.memo_cache_sentinel")) {
|
|
413
|
-
t45 = (e_4) => setEnNumFmt(e_4.target.value);
|
|
414
|
-
t46 = numberFormatOptions.map(_temp2);
|
|
415
|
-
$[81] = t45;
|
|
416
|
-
$[82] = t46;
|
|
417
|
-
} else {
|
|
418
|
-
t45 = $[81];
|
|
419
|
-
t46 = $[82];
|
|
420
|
-
}
|
|
421
|
-
let t47;
|
|
422
|
-
if ($[83] !== enNumFmt || $[84] !== fieldIds.enNumFmt) {
|
|
423
|
-
t47 = /* @__PURE__ */ jsx("select", {
|
|
424
|
-
id: t44,
|
|
425
|
-
className: "border-input bg-background text-foreground mb-2 w-full rounded border px-2 py-1 text-[13px] outline-none",
|
|
426
|
-
value: enNumFmt,
|
|
427
|
-
onChange: t45,
|
|
428
|
-
children: t46
|
|
429
|
-
});
|
|
430
|
-
$[83] = enNumFmt;
|
|
431
|
-
$[84] = fieldIds.enNumFmt;
|
|
432
|
-
$[85] = t47;
|
|
433
|
-
} else t47 = $[85];
|
|
434
|
-
let t48;
|
|
435
|
-
if ($[86] !== fieldIds.enStartAt) {
|
|
436
|
-
t48 = /* @__PURE__ */ jsx("label", {
|
|
437
|
-
htmlFor: fieldIds.enStartAt,
|
|
438
|
-
className: "block text-muted-foreground mb-1 text-xs",
|
|
439
|
-
children: "Start at"
|
|
440
|
-
});
|
|
441
|
-
$[86] = fieldIds.enStartAt;
|
|
442
|
-
$[87] = t48;
|
|
443
|
-
} else t48 = $[87];
|
|
444
|
-
let t49;
|
|
445
|
-
if ($[88] === Symbol.for("react.memo_cache_sentinel")) {
|
|
446
|
-
t49 = (e_5) => setEnNumStart(Number.parseInt(e_5.target.value, 10) || 1);
|
|
447
|
-
$[88] = t49;
|
|
448
|
-
} else t49 = $[88];
|
|
449
|
-
let t50;
|
|
450
|
-
if ($[89] !== enNumStart || $[90] !== fieldIds.enStartAt) {
|
|
451
|
-
t50 = /* @__PURE__ */ jsx("input", {
|
|
452
|
-
id: fieldIds.enStartAt,
|
|
453
|
-
type: "number",
|
|
454
|
-
min: 1,
|
|
455
|
-
className: "border-input bg-background text-foreground w-[60px] rounded border px-2 py-1 text-[13px] outline-none",
|
|
456
|
-
value: enNumStart,
|
|
457
|
-
onChange: t49
|
|
458
|
-
});
|
|
459
|
-
$[89] = enNumStart;
|
|
460
|
-
$[90] = fieldIds.enStartAt;
|
|
461
|
-
$[91] = t50;
|
|
462
|
-
} else t50 = $[91];
|
|
463
|
-
let t51;
|
|
464
|
-
if ($[92] !== t48 || $[93] !== t50) {
|
|
465
|
-
t51 = /* @__PURE__ */ jsxs("div", { children: [t48, t50] });
|
|
466
|
-
$[92] = t48;
|
|
467
|
-
$[93] = t50;
|
|
468
|
-
$[94] = t51;
|
|
469
|
-
} else t51 = $[94];
|
|
470
|
-
let t52;
|
|
471
|
-
if ($[95] !== fieldIds.enNumbering) {
|
|
472
|
-
t52 = /* @__PURE__ */ jsx("label", {
|
|
473
|
-
htmlFor: fieldIds.enNumbering,
|
|
474
|
-
className: "block text-muted-foreground mb-1 text-xs",
|
|
475
|
-
children: "Numbering"
|
|
476
|
-
});
|
|
477
|
-
$[95] = fieldIds.enNumbering;
|
|
478
|
-
$[96] = t52;
|
|
479
|
-
} else t52 = $[96];
|
|
480
|
-
let t53;
|
|
481
|
-
let t54;
|
|
482
|
-
let t55;
|
|
483
|
-
if ($[97] === Symbol.for("react.memo_cache_sentinel")) {
|
|
484
|
-
t53 = (e_6) => setEnRestart(e_6.target.value);
|
|
485
|
-
t54 = /* @__PURE__ */ jsx("option", {
|
|
486
|
-
value: "continuous",
|
|
487
|
-
children: "Continuous"
|
|
488
|
-
});
|
|
489
|
-
t55 = /* @__PURE__ */ jsx("option", {
|
|
490
|
-
value: "eachSect",
|
|
491
|
-
children: "Restart each section"
|
|
492
|
-
});
|
|
493
|
-
$[97] = t53;
|
|
494
|
-
$[98] = t54;
|
|
495
|
-
$[99] = t55;
|
|
496
|
-
} else {
|
|
497
|
-
t53 = $[97];
|
|
498
|
-
t54 = $[98];
|
|
499
|
-
t55 = $[99];
|
|
500
|
-
}
|
|
501
|
-
let t56;
|
|
502
|
-
if ($[100] !== enRestart || $[101] !== fieldIds.enNumbering) {
|
|
503
|
-
t56 = /* @__PURE__ */ jsxs("select", {
|
|
504
|
-
id: fieldIds.enNumbering,
|
|
505
|
-
className: "border-input bg-background text-foreground mb-2 w-full rounded border px-2 py-1 text-[13px] outline-none",
|
|
506
|
-
value: enRestart,
|
|
507
|
-
onChange: t53,
|
|
508
|
-
children: [t54, t55]
|
|
509
|
-
});
|
|
510
|
-
$[100] = enRestart;
|
|
511
|
-
$[101] = fieldIds.enNumbering;
|
|
512
|
-
$[102] = t56;
|
|
513
|
-
} else t56 = $[102];
|
|
514
|
-
let t57;
|
|
515
|
-
if ($[103] !== t52 || $[104] !== t56) {
|
|
516
|
-
t57 = /* @__PURE__ */ jsxs("div", {
|
|
517
|
-
className: "flex-1",
|
|
518
|
-
children: [t52, t56]
|
|
519
|
-
});
|
|
520
|
-
$[103] = t52;
|
|
521
|
-
$[104] = t56;
|
|
522
|
-
$[105] = t57;
|
|
523
|
-
} else t57 = $[105];
|
|
524
|
-
let t58;
|
|
525
|
-
if ($[106] !== t51 || $[107] !== t57) {
|
|
526
|
-
t58 = /* @__PURE__ */ jsxs("div", {
|
|
527
|
-
className: "flex items-center gap-3",
|
|
528
|
-
children: [t51, t57]
|
|
529
|
-
});
|
|
530
|
-
$[106] = t51;
|
|
531
|
-
$[107] = t57;
|
|
532
|
-
$[108] = t58;
|
|
533
|
-
} else t58 = $[108];
|
|
534
|
-
let t59;
|
|
535
|
-
if ($[109] !== t38 || $[110] !== t42 || $[111] !== t43 || $[112] !== t47 || $[113] !== t58) {
|
|
536
|
-
t59 = /* @__PURE__ */ jsxs("div", {
|
|
537
|
-
className: "mb-4 rounded border p-3",
|
|
538
|
-
children: [
|
|
539
|
-
t37,
|
|
540
|
-
t38,
|
|
541
|
-
t42,
|
|
542
|
-
t43,
|
|
543
|
-
t47,
|
|
544
|
-
t58
|
|
545
|
-
]
|
|
546
|
-
});
|
|
547
|
-
$[109] = t38;
|
|
548
|
-
$[110] = t42;
|
|
549
|
-
$[111] = t43;
|
|
550
|
-
$[112] = t47;
|
|
551
|
-
$[113] = t58;
|
|
552
|
-
$[114] = t59;
|
|
553
|
-
} else t59 = $[114];
|
|
554
|
-
let t60;
|
|
555
|
-
if ($[115] !== t36 || $[116] !== t59) {
|
|
556
|
-
t60 = /* @__PURE__ */ jsxs("div", {
|
|
557
|
-
className: "flex flex-col gap-3 px-5 py-4",
|
|
558
|
-
children: [t36, t59]
|
|
559
|
-
});
|
|
560
|
-
$[115] = t36;
|
|
561
|
-
$[116] = t59;
|
|
562
|
-
$[117] = t60;
|
|
563
|
-
} else t60 = $[117];
|
|
564
|
-
let t61;
|
|
565
|
-
if ($[118] !== DialogClose) {
|
|
566
|
-
t61 = /* @__PURE__ */ jsx(DialogClose, {
|
|
567
|
-
className: "border-input rounded border px-4 py-1.5 text-[13px]",
|
|
568
|
-
children: "Cancel"
|
|
569
|
-
});
|
|
570
|
-
$[118] = DialogClose;
|
|
571
|
-
$[119] = t61;
|
|
572
|
-
} else t61 = $[119];
|
|
573
|
-
let t62;
|
|
574
|
-
if ($[120] !== handleApply) {
|
|
575
|
-
t62 = /* @__PURE__ */ jsx("button", {
|
|
576
|
-
className: "bg-primary text-primary-foreground rounded px-4 py-1.5 text-[13px] font-medium",
|
|
577
|
-
onClick: handleApply,
|
|
578
|
-
type: "button",
|
|
579
|
-
children: "Apply"
|
|
580
|
-
});
|
|
581
|
-
$[120] = handleApply;
|
|
582
|
-
$[121] = t62;
|
|
583
|
-
} else t62 = $[121];
|
|
584
|
-
let t63;
|
|
585
|
-
if ($[122] !== t61 || $[123] !== t62) {
|
|
586
|
-
t63 = /* @__PURE__ */ jsxs("div", {
|
|
587
|
-
className: "flex justify-end gap-2 border-t px-5 py-3",
|
|
588
|
-
children: [t61, t62]
|
|
589
|
-
});
|
|
590
|
-
$[122] = t61;
|
|
591
|
-
$[123] = t62;
|
|
592
|
-
$[124] = t63;
|
|
593
|
-
} else t63 = $[124];
|
|
594
|
-
let t64;
|
|
595
|
-
if ($[125] !== DialogPopup || $[126] !== t12 || $[127] !== t60 || $[128] !== t63) {
|
|
596
|
-
t64 = /* @__PURE__ */ jsxs(DialogPopup, {
|
|
597
|
-
className: "bg-popover fixed start-1/2 top-1/2 z-[10001] w-full max-w-[500px] min-w-[400px] -translate-x-1/2 -translate-y-1/2 rounded-lg border shadow-xl",
|
|
598
|
-
children: [
|
|
599
|
-
t12,
|
|
600
|
-
t60,
|
|
601
|
-
t63
|
|
602
|
-
]
|
|
603
|
-
});
|
|
604
|
-
$[125] = DialogPopup;
|
|
605
|
-
$[126] = t12;
|
|
606
|
-
$[127] = t60;
|
|
607
|
-
$[128] = t63;
|
|
608
|
-
$[129] = t64;
|
|
609
|
-
} else t64 = $[129];
|
|
610
|
-
let t65;
|
|
611
|
-
if ($[130] !== DialogPortal || $[131] !== t11 || $[132] !== t64) {
|
|
612
|
-
t65 = /* @__PURE__ */ jsxs(DialogPortal, { children: [t11, t64] });
|
|
613
|
-
$[130] = DialogPortal;
|
|
614
|
-
$[131] = t11;
|
|
615
|
-
$[132] = t64;
|
|
616
|
-
$[133] = t65;
|
|
617
|
-
} else t65 = $[133];
|
|
618
|
-
let t66;
|
|
619
|
-
if ($[134] !== Dialog || $[135] !== handleOpenChange || $[136] !== isOpen || $[137] !== t65) {
|
|
620
|
-
t66 = /* @__PURE__ */ jsx(Dialog, {
|
|
621
|
-
open: isOpen,
|
|
622
|
-
onOpenChange: handleOpenChange,
|
|
623
|
-
children: t65
|
|
624
|
-
});
|
|
625
|
-
$[134] = Dialog;
|
|
626
|
-
$[135] = handleOpenChange;
|
|
627
|
-
$[136] = isOpen;
|
|
628
|
-
$[137] = t65;
|
|
629
|
-
$[138] = t66;
|
|
630
|
-
} else t66 = $[138];
|
|
631
|
-
return t66;
|
|
632
|
-
}
|
|
633
|
-
function _temp2(o_0) {
|
|
634
|
-
return /* @__PURE__ */ jsx("option", {
|
|
635
|
-
value: o_0.value,
|
|
636
|
-
children: o_0.label
|
|
637
|
-
}, o_0.value);
|
|
638
|
-
}
|
|
639
|
-
function _temp(o) {
|
|
640
|
-
return /* @__PURE__ */ jsx("option", {
|
|
641
|
-
value: o.value,
|
|
642
|
-
children: o.label
|
|
643
|
-
}, o.value);
|
|
644
|
-
}
|
|
645
|
-
//#endregion
|
|
646
|
-
export { FootnotePropertiesDialog_exports as n, FootnotePropertiesDialog as t };
|