@levo-so/site-runtime 0.3.17 → 0.3.19
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/CollectionField-C-6a1ud4.js +270 -0
- package/DateTimeWidget-U3lD0q1q.js +255 -0
- package/{Dialog-D-vRkU9N.js → Dialog-dT7y641z.js} +1 -1
- package/{KBChatWidget-BMuZ-VI3.js → KBChatWidget-GRi6sLpp.js} +222 -222
- package/{LevoProvider-BkbKrvrI.js → LevoProvider-Bsjkcwc8.js} +8 -8
- package/PhoneWidget-DQQa4bL6.js +99 -0
- package/{Popover-Cr0-X_ch.js → Popover-C29yJ7rz.js} +1 -1
- package/{PopupBody-BI-MJqmd-BnSl6jJr.js → PopupBody-BI-MJqmd-DgTQEzda.js} +23 -23
- package/{PopupRenderer-D66Gx63H-B_CFOeCl.js → PopupRenderer-D66Gx63H-Cd9xJv33.js} +47 -47
- package/{RichTextWidget-C1QECDcg.js → RichTextWidget-DfakML79.js} +127 -127
- package/{RteThemeProvider-CMbSaFRQ.js → RteThemeProvider-BQmfSXSl.js} +1 -1
- package/{ThemeProvider-DlFehjh1.js → ThemeProvider-DutrjSTF.js} +30 -30
- package/{Tooltip-BKQ5rIDh.js → Tooltip-CQB0LyxK.js} +1 -1
- package/{VerifyButton-D0cj9Z5Q.js → VerifyButton-BUT70lgz.js} +38 -38
- package/blog-content.js +67 -67
- package/{dist-C6-eVcUB.js → dist-6AIgW_iB.js} +10 -10
- package/{dist-CXoCodlj.js → dist-CEdznbFW.js} +1099 -1175
- package/index.d.ts +2 -6
- package/index.js +407 -411
- package/{kbChat-DtZ4vuCZ.js → kbChat-a2dXSeRc.js} +26 -26
- package/package.json +3 -3
- package/popups.js +1 -1
- package/{usePopupRedirect-CAAdcpaW-BDa44PXN.js → usePopupRedirect-CAAdcpaW-Ddjyf4KK.js} +14 -14
- package/CollectionField-DCAXOmBN.js +0 -270
- package/DateTimeWidget-I0LvR-tO.js +0 -255
- package/PhoneWidget-DPECohGT.js +0 -99
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { n as e, r as t, t as n } from "./CollectionField-
|
|
3
|
-
import { r } from "./ThemeProvider-
|
|
4
|
-
import { i, n as a, r as o, t as s } from "./Tooltip-
|
|
2
|
+
import { n as e, r as t, t as n } from "./CollectionField-C-6a1ud4.js";
|
|
3
|
+
import { r } from "./ThemeProvider-DutrjSTF.js";
|
|
4
|
+
import { i, n as a, r as o, t as s } from "./Tooltip-CQB0LyxK.js";
|
|
5
5
|
import { n as c, t as l } from "./content.cssm-XdMsTGIB.js";
|
|
6
6
|
import { t as u } from "./inlineRteTheme-CRPtkNXy.js";
|
|
7
|
-
import { t as d } from "./RteThemeProvider-
|
|
8
|
-
import { a as f, i as p, n as m, o as h, r as g } from "./Popover-
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import
|
|
12
|
-
import S from "
|
|
13
|
-
import {
|
|
7
|
+
import { t as d } from "./RteThemeProvider-BQmfSXSl.js";
|
|
8
|
+
import { a as f, i as p, n as m, o as h, r as g } from "./Popover-C29yJ7rz.js";
|
|
9
|
+
import { useController as _ } from "react-hook-form";
|
|
10
|
+
import { c as v } from "react/compiler-runtime";
|
|
11
|
+
import y from "clsx";
|
|
12
|
+
import { Fragment as b, jsx as x, jsxs as S } from "react/jsx-runtime";
|
|
13
|
+
import { forwardRef as C, useEffect as w, useState as T } from "react";
|
|
14
14
|
import { IconAlignCenter as E, IconAlignJustified as D, IconAlignLeft as O, IconAlignRight as ee, IconArrowBackUp as te, IconArrowForwardUp as k, IconBold as A, IconChevronDown as j, IconCode as M, IconCornerDownLeft as ne, IconExternalLink as N, IconH1 as P, IconH2 as F, IconH3 as I, IconH4 as L, IconH5 as R, IconH6 as z, IconItalic as B, IconLink as re, IconList as V, IconListNumbers as H, IconPencil as U, IconPilcrow as W, IconRotate2 as G, IconStrikethrough as K, IconSubscript as q, IconSuperscript as J, IconTrash as Y, IconUnderline as X } from "@tabler/icons-react";
|
|
15
15
|
import { AllSelection as Z, NodeSelection as ie, TextSelection as Q } from "@tiptap/pm/state";
|
|
16
16
|
import { Subscript as ae } from "@tiptap/extension-subscript";
|
|
@@ -44,17 +44,17 @@ var _e = (e = { placeholder: "Write something ..." }) => [
|
|
|
44
44
|
"bulletList",
|
|
45
45
|
"orderedList"
|
|
46
46
|
] })
|
|
47
|
-
], ve = "_261ja30", ye = "_261ja31", $ =
|
|
48
|
-
let n =
|
|
47
|
+
], ve = "_261ja30", ye = "_261ja31", $ = C((e, t) => {
|
|
48
|
+
let n = v(27), i, c, l, u, d, f, p;
|
|
49
49
|
n[0] === e ? (i = n[1], c = n[2], l = n[3], u = n[4], d = n[5], f = n[6], p = n[7]) : ({label: u, Icon: i, isActive: l, iconSize: f, trailing: p, className: c, ...d} = e, n[0] = e, n[1] = i, n[2] = c, n[3] = l, n[4] = u, n[5] = d, n[6] = f, n[7] = p);
|
|
50
|
-
let m = f === void 0 ? 16 : f, h = l || void 0, g = l && "_1vaxhty0",
|
|
51
|
-
n[8] !== c || n[9] !== g ? (
|
|
52
|
-
let y;
|
|
53
|
-
n[11] !== i || n[12] !== m ? (y = /* @__PURE__ */ w(i, { size: m }), n[11] = i, n[12] = m, n[13] = y) : y = n[13];
|
|
50
|
+
let m = f === void 0 ? 16 : f, h = l || void 0, g = l && "_1vaxhty0", _;
|
|
51
|
+
n[8] !== c || n[9] !== g ? (_ = y(g, c), n[8] = c, n[9] = g, n[10] = _) : _ = n[10];
|
|
54
52
|
let b;
|
|
55
|
-
n[
|
|
53
|
+
n[11] !== i || n[12] !== m ? (b = /* @__PURE__ */ x(i, { size: m }), n[11] = i, n[12] = m, n[13] = b) : b = n[13];
|
|
54
|
+
let C;
|
|
55
|
+
n[14] !== u || n[15] !== d || n[16] !== t || n[17] !== h || n[18] !== _ || n[19] !== b || n[20] !== p ? (C = /* @__PURE__ */ x(a, {
|
|
56
56
|
onPointerDown: be,
|
|
57
|
-
render: /* @__PURE__ */
|
|
57
|
+
render: /* @__PURE__ */ S(r, {
|
|
58
58
|
ref: t,
|
|
59
59
|
type: "button",
|
|
60
60
|
variant: "ghost",
|
|
@@ -62,15 +62,15 @@ var _e = (e = { placeholder: "Write something ..." }) => [
|
|
|
62
62
|
tabIndex: -1,
|
|
63
63
|
"aria-label": u,
|
|
64
64
|
"aria-pressed": h,
|
|
65
|
-
className:
|
|
65
|
+
className: _,
|
|
66
66
|
...d,
|
|
67
|
-
children: [
|
|
67
|
+
children: [b, p]
|
|
68
68
|
})
|
|
69
|
-
}), n[14] = u, n[15] = d, n[16] = t, n[17] = h, n[18] =
|
|
70
|
-
let
|
|
71
|
-
n[22] === u ?
|
|
72
|
-
let
|
|
73
|
-
return n[24] !==
|
|
69
|
+
}), n[14] = u, n[15] = d, n[16] = t, n[17] = h, n[18] = _, n[19] = b, n[20] = p, n[21] = C) : C = n[21];
|
|
70
|
+
let w;
|
|
71
|
+
n[22] === u ? w = n[23] : (w = /* @__PURE__ */ x(o, { children: u }), n[22] = u, n[23] = w);
|
|
72
|
+
let T;
|
|
73
|
+
return n[24] !== C || n[25] !== w ? (T = /* @__PURE__ */ S(s, { children: [C, w] }), n[24] = C, n[25] = w, n[26] = T) : T = n[26], T;
|
|
74
74
|
});
|
|
75
75
|
$.displayName = "ToolbarButton";
|
|
76
76
|
function be(e) {
|
|
@@ -138,21 +138,21 @@ var xe = [
|
|
|
138
138
|
}
|
|
139
139
|
return !1;
|
|
140
140
|
}, Ae = "j67x6z0", je = "j67x6z1", Me = "_5pk5r80", Ne = (e) => {
|
|
141
|
-
let t =
|
|
141
|
+
let t = v(50), { editor: n } = e, [r, i] = T(!1), { isActive: c, currentUrl: l } = ge({
|
|
142
142
|
editor: n,
|
|
143
143
|
selector: Pe
|
|
144
144
|
}) ?? {
|
|
145
145
|
isActive: !1,
|
|
146
146
|
currentUrl: ""
|
|
147
|
-
}, [u, d] =
|
|
148
|
-
t[0] !== l || t[1] !== r ? (
|
|
147
|
+
}, [u, d] = T(l), _, y;
|
|
148
|
+
t[0] !== l || t[1] !== r ? (_ = () => {
|
|
149
149
|
r && d(l);
|
|
150
|
-
},
|
|
151
|
-
let
|
|
152
|
-
t[4] !== n || t[5] !== u ? (
|
|
150
|
+
}, y = [r, l], t[0] = l, t[1] = r, t[2] = _, t[3] = y) : (_ = t[2], y = t[3]), w(_, y);
|
|
151
|
+
let b;
|
|
152
|
+
t[4] !== n || t[5] !== u ? (b = () => {
|
|
153
153
|
u && (n.chain().focus().extendMarkRange("link").setLink({ href: u }).run(), i(!1));
|
|
154
|
-
}, t[4] = n, t[5] = u, t[6] =
|
|
155
|
-
let C =
|
|
154
|
+
}, t[4] = n, t[5] = u, t[6] = b) : b = t[6];
|
|
155
|
+
let C = b, E;
|
|
156
156
|
t[7] === n ? E = t[8] : (E = () => {
|
|
157
157
|
n.chain().focus().extendMarkRange("link").unsetLink().run(), d(""), i(!1);
|
|
158
158
|
}, t[7] = n, t[8] = E);
|
|
@@ -166,9 +166,9 @@ var xe = [
|
|
|
166
166
|
e.preventDefault(), i(!0);
|
|
167
167
|
}, t[11] = te) : te = t[11];
|
|
168
168
|
let k;
|
|
169
|
-
t[12] === c ? k = t[13] : (k = /* @__PURE__ */
|
|
169
|
+
t[12] === c ? k = t[13] : (k = /* @__PURE__ */ x(h, {
|
|
170
170
|
onPointerDown: Fe,
|
|
171
|
-
render: /* @__PURE__ */
|
|
171
|
+
render: /* @__PURE__ */ x($, {
|
|
172
172
|
label: "Link",
|
|
173
173
|
Icon: re,
|
|
174
174
|
isActive: c,
|
|
@@ -182,7 +182,7 @@ var xe = [
|
|
|
182
182
|
e.key === "Enter" && (e.preventDefault(), C());
|
|
183
183
|
}, t[15] = C, t[16] = j);
|
|
184
184
|
let M;
|
|
185
|
-
t[17] !== j || t[18] !== u ? (M = /* @__PURE__ */
|
|
185
|
+
t[17] !== j || t[18] !== u ? (M = /* @__PURE__ */ x("input", {
|
|
186
186
|
className: je,
|
|
187
187
|
value: u,
|
|
188
188
|
onChange: A,
|
|
@@ -190,9 +190,9 @@ var xe = [
|
|
|
190
190
|
placeholder: "Paste a link..."
|
|
191
191
|
}), t[17] = j, t[18] = u, t[19] = M) : M = t[19];
|
|
192
192
|
let P = !u && !c, F;
|
|
193
|
-
t[20] === Symbol.for("react.memo_cache_sentinel") ? (F = /* @__PURE__ */
|
|
193
|
+
t[20] === Symbol.for("react.memo_cache_sentinel") ? (F = /* @__PURE__ */ x(ne, { size: 16 }), t[20] = F) : F = t[20];
|
|
194
194
|
let I;
|
|
195
|
-
t[21] !== C || t[22] !== P ? (I = /* @__PURE__ */
|
|
195
|
+
t[21] !== C || t[22] !== P ? (I = /* @__PURE__ */ x(a, { render: /* @__PURE__ */ x("button", {
|
|
196
196
|
type: "button",
|
|
197
197
|
className: Me,
|
|
198
198
|
onClick: C,
|
|
@@ -201,13 +201,13 @@ var xe = [
|
|
|
201
201
|
children: F
|
|
202
202
|
}) }), t[21] = C, t[22] = P, t[23] = I) : I = t[23];
|
|
203
203
|
let L;
|
|
204
|
-
t[24] === Symbol.for("react.memo_cache_sentinel") ? (L = /* @__PURE__ */
|
|
204
|
+
t[24] === Symbol.for("react.memo_cache_sentinel") ? (L = /* @__PURE__ */ x(o, { children: "Apply link" }), t[24] = L) : L = t[24];
|
|
205
205
|
let R;
|
|
206
|
-
t[25] === I ? R = t[26] : (R = /* @__PURE__ */
|
|
206
|
+
t[25] === I ? R = t[26] : (R = /* @__PURE__ */ S(s, { children: [I, L] }), t[25] = I, t[26] = R);
|
|
207
207
|
let z = !u && !c, B;
|
|
208
|
-
t[27] === Symbol.for("react.memo_cache_sentinel") ? (B = /* @__PURE__ */
|
|
208
|
+
t[27] === Symbol.for("react.memo_cache_sentinel") ? (B = /* @__PURE__ */ x(N, { size: 16 }), t[27] = B) : B = t[27];
|
|
209
209
|
let V;
|
|
210
|
-
t[28] !== ee || t[29] !== z ? (V = /* @__PURE__ */
|
|
210
|
+
t[28] !== ee || t[29] !== z ? (V = /* @__PURE__ */ x(a, { render: /* @__PURE__ */ x("button", {
|
|
211
211
|
type: "button",
|
|
212
212
|
className: Me,
|
|
213
213
|
onClick: ee,
|
|
@@ -216,13 +216,13 @@ var xe = [
|
|
|
216
216
|
children: B
|
|
217
217
|
}) }), t[28] = ee, t[29] = z, t[30] = V) : V = t[30];
|
|
218
218
|
let H;
|
|
219
|
-
t[31] === Symbol.for("react.memo_cache_sentinel") ? (H = /* @__PURE__ */
|
|
219
|
+
t[31] === Symbol.for("react.memo_cache_sentinel") ? (H = /* @__PURE__ */ x(o, { children: "Open in new window" }), t[31] = H) : H = t[31];
|
|
220
220
|
let U;
|
|
221
|
-
t[32] === V ? U = t[33] : (U = /* @__PURE__ */
|
|
221
|
+
t[32] === V ? U = t[33] : (U = /* @__PURE__ */ S(s, { children: [V, H] }), t[32] = V, t[33] = U);
|
|
222
222
|
let W = !u && !c, G;
|
|
223
|
-
t[34] === Symbol.for("react.memo_cache_sentinel") ? (G = /* @__PURE__ */
|
|
223
|
+
t[34] === Symbol.for("react.memo_cache_sentinel") ? (G = /* @__PURE__ */ x(Y, { size: 16 }), t[34] = G) : G = t[34];
|
|
224
224
|
let K;
|
|
225
|
-
t[35] !== D || t[36] !== W ? (K = /* @__PURE__ */
|
|
225
|
+
t[35] !== D || t[36] !== W ? (K = /* @__PURE__ */ x(a, { render: /* @__PURE__ */ x("button", {
|
|
226
226
|
type: "button",
|
|
227
227
|
className: Me,
|
|
228
228
|
onClick: D,
|
|
@@ -231,14 +231,14 @@ var xe = [
|
|
|
231
231
|
children: G
|
|
232
232
|
}) }), t[35] = D, t[36] = W, t[37] = K) : K = t[37];
|
|
233
233
|
let q;
|
|
234
|
-
t[38] === Symbol.for("react.memo_cache_sentinel") ? (q = /* @__PURE__ */
|
|
234
|
+
t[38] === Symbol.for("react.memo_cache_sentinel") ? (q = /* @__PURE__ */ x(o, { children: "Remove link" }), t[38] = q) : q = t[38];
|
|
235
235
|
let J;
|
|
236
|
-
t[39] === K ? J = t[40] : (J = /* @__PURE__ */
|
|
236
|
+
t[39] === K ? J = t[40] : (J = /* @__PURE__ */ S(s, { children: [K, q] }), t[39] = K, t[40] = J);
|
|
237
237
|
let X;
|
|
238
|
-
t[41] !== M || t[42] !== R || t[43] !== U || t[44] !== J ? (X = /* @__PURE__ */
|
|
238
|
+
t[41] !== M || t[42] !== R || t[43] !== U || t[44] !== J ? (X = /* @__PURE__ */ x(p, { children: /* @__PURE__ */ x(g, {
|
|
239
239
|
side: "bottom",
|
|
240
240
|
align: "center",
|
|
241
|
-
children: /* @__PURE__ */
|
|
241
|
+
children: /* @__PURE__ */ S(f.Popup, {
|
|
242
242
|
className: Ae,
|
|
243
243
|
children: [
|
|
244
244
|
M,
|
|
@@ -249,7 +249,7 @@ var xe = [
|
|
|
249
249
|
})
|
|
250
250
|
}) }), t[41] = M, t[42] = R, t[43] = U, t[44] = J, t[45] = X) : X = t[45];
|
|
251
251
|
let Z;
|
|
252
|
-
return t[46] !== r || t[47] !== X || t[48] !== k ? (Z = /* @__PURE__ */
|
|
252
|
+
return t[46] !== r || t[47] !== X || t[48] !== k ? (Z = /* @__PURE__ */ S(m, {
|
|
253
253
|
open: r,
|
|
254
254
|
onOpenChange: i,
|
|
255
255
|
children: [k, X]
|
|
@@ -341,58 +341,58 @@ var Ie = "_1keigwl0", Le = "_1keigwl1 _5pk5r80", Re = (e) => (t) => t.chain().fo
|
|
|
341
341
|
apply: (e) => e.chain().focus().toggleOrderedList().run()
|
|
342
342
|
}
|
|
343
343
|
], Be = (e) => {
|
|
344
|
-
let t =
|
|
344
|
+
let t = v(19), { editor: n } = e, [r, i] = T(!1), { activeBlock: a, canConvert: o, structural: s } = ge({
|
|
345
345
|
editor: n,
|
|
346
346
|
selector: Ve
|
|
347
347
|
}) ?? {
|
|
348
348
|
activeBlock: null,
|
|
349
349
|
canConvert: !1,
|
|
350
350
|
structural: !1
|
|
351
|
-
}, c = a?.Icon ?? U, l = a?.label ?? "Turn Into", u = s || !o, d,
|
|
352
|
-
t[0] === Symbol.for("react.memo_cache_sentinel") ? (d = /* @__PURE__ */
|
|
351
|
+
}, c = a?.Icon ?? U, l = a?.label ?? "Turn Into", u = s || !o, d, _;
|
|
352
|
+
t[0] === Symbol.for("react.memo_cache_sentinel") ? (d = /* @__PURE__ */ x(j, { size: 12 }), _ = (e) => {
|
|
353
353
|
e.preventDefault(), i(!0);
|
|
354
|
-
}, t[0] = d, t[1] =
|
|
354
|
+
}, t[0] = d, t[1] = _) : (d = t[0], _ = t[1]);
|
|
355
355
|
let y;
|
|
356
|
-
t[2] !== c || t[3] !== u || t[4] !== l ? (y = /* @__PURE__ */
|
|
356
|
+
t[2] !== c || t[3] !== u || t[4] !== l ? (y = /* @__PURE__ */ x(h, {
|
|
357
357
|
onPointerDown: He,
|
|
358
|
-
render: /* @__PURE__ */
|
|
358
|
+
render: /* @__PURE__ */ x($, {
|
|
359
359
|
label: l,
|
|
360
360
|
Icon: c,
|
|
361
361
|
disabled: u,
|
|
362
362
|
trailing: d,
|
|
363
|
-
onClick:
|
|
363
|
+
onClick: _
|
|
364
364
|
})
|
|
365
365
|
}), t[2] = c, t[3] = u, t[4] = l, t[5] = y) : y = t[5];
|
|
366
|
-
let
|
|
366
|
+
let b;
|
|
367
367
|
if (t[6] !== a?.type || t[7] !== n) {
|
|
368
368
|
let e;
|
|
369
369
|
t[9] === a?.type ? e = t[10] : (e = (e) => a?.type !== e.type, t[9] = a?.type, t[10] = e);
|
|
370
370
|
let r;
|
|
371
|
-
t[11] === n ? r = t[12] : (r = (e) => /* @__PURE__ */
|
|
371
|
+
t[11] === n ? r = t[12] : (r = (e) => /* @__PURE__ */ S("button", {
|
|
372
372
|
type: "button",
|
|
373
373
|
className: Le,
|
|
374
374
|
disabled: !e.canApply(n),
|
|
375
375
|
onClick: () => {
|
|
376
376
|
e.apply(n), i(!1);
|
|
377
377
|
},
|
|
378
|
-
children: [/* @__PURE__ */
|
|
379
|
-
}, e.type), t[11] = n, t[12] = r),
|
|
380
|
-
} else
|
|
381
|
-
let
|
|
382
|
-
t[13] ===
|
|
378
|
+
children: [/* @__PURE__ */ x(e.Icon, { size: 16 }), /* @__PURE__ */ x("span", { children: e.label })]
|
|
379
|
+
}, e.type), t[11] = n, t[12] = r), b = ze.filter(e).map(r), t[6] = a?.type, t[7] = n, t[8] = b;
|
|
380
|
+
} else b = t[8];
|
|
381
|
+
let C;
|
|
382
|
+
t[13] === b ? C = t[14] : (C = /* @__PURE__ */ x(p, { children: /* @__PURE__ */ x(g, {
|
|
383
383
|
side: "bottom",
|
|
384
384
|
align: "start",
|
|
385
|
-
children: /* @__PURE__ */
|
|
385
|
+
children: /* @__PURE__ */ x(f.Popup, {
|
|
386
386
|
className: Ie,
|
|
387
|
-
children:
|
|
387
|
+
children: b
|
|
388
388
|
})
|
|
389
|
-
}) }), t[13] =
|
|
390
|
-
let
|
|
391
|
-
return t[15] !== r || t[16] !== y || t[17] !==
|
|
389
|
+
}) }), t[13] = b, t[14] = C);
|
|
390
|
+
let w;
|
|
391
|
+
return t[15] !== r || t[16] !== y || t[17] !== C ? (w = /* @__PURE__ */ S(m, {
|
|
392
392
|
open: r,
|
|
393
393
|
onOpenChange: i,
|
|
394
|
-
children: [y,
|
|
395
|
-
}), t[15] = r, t[16] = y, t[17] =
|
|
394
|
+
children: [y, C]
|
|
395
|
+
}), t[15] = r, t[16] = y, t[17] = C, t[18] = w) : w = t[18], w;
|
|
396
396
|
};
|
|
397
397
|
function Ve(e) {
|
|
398
398
|
let { editor: t } = e;
|
|
@@ -463,7 +463,7 @@ var Ue = [
|
|
|
463
463
|
Icon: D
|
|
464
464
|
}
|
|
465
465
|
], Ke = (e) => {
|
|
466
|
-
let t =
|
|
466
|
+
let t = v(9), { editor: n, mark: r, label: i, Icon: a } = e, { isActive: o, canExecute: s } = ge({
|
|
467
467
|
editor: n,
|
|
468
468
|
selector: (e) => {
|
|
469
469
|
let { editor: t } = e;
|
|
@@ -478,7 +478,7 @@ var Ue = [
|
|
|
478
478
|
}, c = !s, l;
|
|
479
479
|
t[0] !== n || t[1] !== r ? (l = () => n.chain().focus().toggleMark(r).run(), t[0] = n, t[1] = r, t[2] = l) : l = t[2];
|
|
480
480
|
let u;
|
|
481
|
-
return t[3] !== a || t[4] !== o || t[5] !== i || t[6] !== c || t[7] !== l ? (u = /* @__PURE__ */
|
|
481
|
+
return t[3] !== a || t[4] !== o || t[5] !== i || t[6] !== c || t[7] !== l ? (u = /* @__PURE__ */ x($, {
|
|
482
482
|
label: i,
|
|
483
483
|
Icon: a,
|
|
484
484
|
isActive: o,
|
|
@@ -486,7 +486,7 @@ var Ue = [
|
|
|
486
486
|
onClick: l
|
|
487
487
|
}), t[3] = a, t[4] = o, t[5] = i, t[6] = c, t[7] = l, t[8] = u) : u = t[8], u;
|
|
488
488
|
}, qe = (e) => {
|
|
489
|
-
let t =
|
|
489
|
+
let t = v(9), { editor: n, align: r, label: i, Icon: a } = e, { isActive: o, canExecute: s } = ge({
|
|
490
490
|
editor: n,
|
|
491
491
|
selector: (e) => {
|
|
492
492
|
let { editor: t } = e;
|
|
@@ -501,7 +501,7 @@ var Ue = [
|
|
|
501
501
|
}, c = !s, l;
|
|
502
502
|
t[0] !== r || t[1] !== n ? (l = () => n.chain().focus().setNodeTextAlign(r).run(), t[0] = r, t[1] = n, t[2] = l) : l = t[2];
|
|
503
503
|
let u;
|
|
504
|
-
return t[3] !== a || t[4] !== o || t[5] !== i || t[6] !== c || t[7] !== l ? (u = /* @__PURE__ */
|
|
504
|
+
return t[3] !== a || t[4] !== o || t[5] !== i || t[6] !== c || t[7] !== l ? (u = /* @__PURE__ */ x($, {
|
|
505
505
|
label: i,
|
|
506
506
|
Icon: a,
|
|
507
507
|
isActive: o,
|
|
@@ -509,113 +509,113 @@ var Ue = [
|
|
|
509
509
|
onClick: l
|
|
510
510
|
}), t[3] = a, t[4] = o, t[5] = i, t[6] = c, t[7] = l, t[8] = u) : u = t[8], u;
|
|
511
511
|
}, Je = (e) => {
|
|
512
|
-
let t =
|
|
512
|
+
let t = v(5), { editor: n } = e, r = !(ge({
|
|
513
513
|
editor: n,
|
|
514
514
|
selector: Qe
|
|
515
515
|
}) ?? !1), i;
|
|
516
516
|
t[0] === n ? i = t[1] : (i = () => n.chain().focus().undo().run(), t[0] = n, t[1] = i);
|
|
517
517
|
let a;
|
|
518
|
-
return t[2] !== r || t[3] !== i ? (a = /* @__PURE__ */
|
|
518
|
+
return t[2] !== r || t[3] !== i ? (a = /* @__PURE__ */ x($, {
|
|
519
519
|
label: "Undo",
|
|
520
520
|
Icon: te,
|
|
521
521
|
disabled: r,
|
|
522
522
|
onClick: i
|
|
523
523
|
}), t[2] = r, t[3] = i, t[4] = a) : a = t[4], a;
|
|
524
524
|
}, Ye = (e) => {
|
|
525
|
-
let t =
|
|
525
|
+
let t = v(5), { editor: n } = e, r = !(ge({
|
|
526
526
|
editor: n,
|
|
527
527
|
selector: $e
|
|
528
528
|
}) ?? !1), i;
|
|
529
529
|
t[0] === n ? i = t[1] : (i = () => n.chain().focus().redo().run(), t[0] = n, t[1] = i);
|
|
530
530
|
let a;
|
|
531
|
-
return t[2] !== r || t[3] !== i ? (a = /* @__PURE__ */
|
|
531
|
+
return t[2] !== r || t[3] !== i ? (a = /* @__PURE__ */ x($, {
|
|
532
532
|
label: "Redo",
|
|
533
533
|
Icon: k,
|
|
534
534
|
disabled: r,
|
|
535
535
|
onClick: i
|
|
536
536
|
}), t[2] = r, t[3] = i, t[4] = a) : a = t[4], a;
|
|
537
537
|
}, Xe = (e) => {
|
|
538
|
-
let t =
|
|
538
|
+
let t = v(5), { editor: n } = e, r = !(ge({
|
|
539
539
|
editor: n,
|
|
540
540
|
selector: et
|
|
541
541
|
}) ?? !1), i;
|
|
542
542
|
t[0] === n ? i = t[1] : (i = () => Oe(n), t[0] = n, t[1] = i);
|
|
543
543
|
let a;
|
|
544
|
-
return t[2] !== r || t[3] !== i ? (a = /* @__PURE__ */
|
|
544
|
+
return t[2] !== r || t[3] !== i ? (a = /* @__PURE__ */ x($, {
|
|
545
545
|
label: "Reset formatting",
|
|
546
546
|
Icon: G,
|
|
547
547
|
disabled: r,
|
|
548
548
|
onClick: i
|
|
549
549
|
}), t[2] = r, t[3] = i, t[4] = a) : a = t[4], a;
|
|
550
550
|
}, Ze = (t) => {
|
|
551
|
-
let n =
|
|
551
|
+
let n = v(33), { children: r } = t, { editor: i } = me();
|
|
552
552
|
if (!i) return null;
|
|
553
553
|
let a;
|
|
554
|
-
n[0] === i ? a = n[1] : (a = /* @__PURE__ */
|
|
554
|
+
n[0] === i ? a = n[1] : (a = /* @__PURE__ */ x("div", {
|
|
555
555
|
className: ye,
|
|
556
|
-
children: /* @__PURE__ */
|
|
556
|
+
children: /* @__PURE__ */ x(Be, { editor: i })
|
|
557
557
|
}), n[0] = i, n[1] = a);
|
|
558
558
|
let o;
|
|
559
|
-
n[2] === Symbol.for("react.memo_cache_sentinel") ? (o = /* @__PURE__ */
|
|
559
|
+
n[2] === Symbol.for("react.memo_cache_sentinel") ? (o = /* @__PURE__ */ x(e, { orientation: "vertical" }), n[2] = o) : o = n[2];
|
|
560
560
|
let s;
|
|
561
|
-
n[3] === i ? s = n[4] : (s = Ue.map((e) => /* @__PURE__ */
|
|
561
|
+
n[3] === i ? s = n[4] : (s = Ue.map((e) => /* @__PURE__ */ x(Ke, {
|
|
562
562
|
editor: i,
|
|
563
563
|
...e
|
|
564
564
|
}, e.mark)), n[3] = i, n[4] = s);
|
|
565
565
|
let c;
|
|
566
|
-
n[5] === s ? c = n[6] : (c = /* @__PURE__ */
|
|
566
|
+
n[5] === s ? c = n[6] : (c = /* @__PURE__ */ x("div", {
|
|
567
567
|
className: ye,
|
|
568
568
|
children: s
|
|
569
569
|
}), n[5] = s, n[6] = c);
|
|
570
570
|
let l;
|
|
571
|
-
n[7] === Symbol.for("react.memo_cache_sentinel") ? (l = /* @__PURE__ */
|
|
571
|
+
n[7] === Symbol.for("react.memo_cache_sentinel") ? (l = /* @__PURE__ */ x(e, { orientation: "vertical" }), n[7] = l) : l = n[7];
|
|
572
572
|
let u;
|
|
573
|
-
n[8] === i ? u = n[9] : (u = /* @__PURE__ */
|
|
573
|
+
n[8] === i ? u = n[9] : (u = /* @__PURE__ */ x("div", {
|
|
574
574
|
className: ye,
|
|
575
|
-
children: /* @__PURE__ */
|
|
575
|
+
children: /* @__PURE__ */ x(Ne, { editor: i })
|
|
576
576
|
}), n[8] = i, n[9] = u);
|
|
577
577
|
let d;
|
|
578
|
-
n[10] === Symbol.for("react.memo_cache_sentinel") ? (d = /* @__PURE__ */
|
|
578
|
+
n[10] === Symbol.for("react.memo_cache_sentinel") ? (d = /* @__PURE__ */ x(e, { orientation: "vertical" }), n[10] = d) : d = n[10];
|
|
579
579
|
let f;
|
|
580
|
-
n[11] === i ? f = n[12] : (f = Ge.map((e) => /* @__PURE__ */
|
|
580
|
+
n[11] === i ? f = n[12] : (f = Ge.map((e) => /* @__PURE__ */ x(qe, {
|
|
581
581
|
editor: i,
|
|
582
582
|
...e
|
|
583
583
|
}, e.align)), n[11] = i, n[12] = f);
|
|
584
584
|
let p;
|
|
585
|
-
n[13] === f ? p = n[14] : (p = /* @__PURE__ */
|
|
585
|
+
n[13] === f ? p = n[14] : (p = /* @__PURE__ */ x("div", {
|
|
586
586
|
className: ye,
|
|
587
587
|
children: f
|
|
588
588
|
}), n[13] = f, n[14] = p);
|
|
589
589
|
let m;
|
|
590
|
-
n[15] === Symbol.for("react.memo_cache_sentinel") ? (m = /* @__PURE__ */
|
|
590
|
+
n[15] === Symbol.for("react.memo_cache_sentinel") ? (m = /* @__PURE__ */ x(e, { orientation: "vertical" }), n[15] = m) : m = n[15];
|
|
591
591
|
let h;
|
|
592
|
-
n[16] === i ? h = n[17] : (h = We.map((e) => /* @__PURE__ */
|
|
592
|
+
n[16] === i ? h = n[17] : (h = We.map((e) => /* @__PURE__ */ x(Ke, {
|
|
593
593
|
editor: i,
|
|
594
594
|
...e
|
|
595
595
|
}, e.mark)), n[16] = i, n[17] = h);
|
|
596
596
|
let g;
|
|
597
|
-
n[18] === h ? g = n[19] : (g = /* @__PURE__ */
|
|
597
|
+
n[18] === h ? g = n[19] : (g = /* @__PURE__ */ x("div", {
|
|
598
598
|
className: ye,
|
|
599
599
|
children: h
|
|
600
600
|
}), n[18] = h, n[19] = g);
|
|
601
|
-
let
|
|
602
|
-
n[20] === Symbol.for("react.memo_cache_sentinel") ? (
|
|
601
|
+
let _;
|
|
602
|
+
n[20] === Symbol.for("react.memo_cache_sentinel") ? (_ = /* @__PURE__ */ x(e, { orientation: "vertical" }), n[20] = _) : _ = n[20];
|
|
603
603
|
let y;
|
|
604
|
-
n[21] === i ? y = n[22] : (y = /* @__PURE__ */
|
|
604
|
+
n[21] === i ? y = n[22] : (y = /* @__PURE__ */ S("div", {
|
|
605
605
|
className: ye,
|
|
606
606
|
children: [
|
|
607
|
-
/* @__PURE__ */
|
|
608
|
-
/* @__PURE__ */
|
|
609
|
-
/* @__PURE__ */
|
|
607
|
+
/* @__PURE__ */ x(Xe, { editor: i }),
|
|
608
|
+
/* @__PURE__ */ x(Je, { editor: i }),
|
|
609
|
+
/* @__PURE__ */ x(Ye, { editor: i })
|
|
610
610
|
]
|
|
611
611
|
}), n[21] = i, n[22] = y);
|
|
612
|
-
let
|
|
613
|
-
n[23] === r ?
|
|
612
|
+
let C;
|
|
613
|
+
n[23] === r ? C = n[24] : (C = r && /* @__PURE__ */ S(b, { children: [/* @__PURE__ */ x(e, { orientation: "vertical" }), /* @__PURE__ */ x("div", {
|
|
614
614
|
className: "_261ja31",
|
|
615
615
|
children: r
|
|
616
|
-
})] }), n[23] = r, n[24] =
|
|
617
|
-
let
|
|
618
|
-
return n[25] !== a || n[26] !== g || n[27] !== y || n[28] !==
|
|
616
|
+
})] }), n[23] = r, n[24] = C);
|
|
617
|
+
let w;
|
|
618
|
+
return n[25] !== a || n[26] !== g || n[27] !== y || n[28] !== C || n[29] !== c || n[30] !== u || n[31] !== p ? (w = /* @__PURE__ */ S("div", {
|
|
619
619
|
className: ve,
|
|
620
620
|
children: [
|
|
621
621
|
a,
|
|
@@ -627,11 +627,11 @@ var Ue = [
|
|
|
627
627
|
p,
|
|
628
628
|
m,
|
|
629
629
|
g,
|
|
630
|
-
|
|
630
|
+
_,
|
|
631
631
|
y,
|
|
632
|
-
|
|
632
|
+
C
|
|
633
633
|
]
|
|
634
|
-
}), n[25] = a, n[26] = g, n[27] = y, n[28] =
|
|
634
|
+
}), n[25] = a, n[26] = g, n[27] = y, n[28] = C, n[29] = c, n[30] = u, n[31] = p, n[32] = w) : w = n[32], w;
|
|
635
635
|
};
|
|
636
636
|
function Qe(e) {
|
|
637
637
|
let { editor: t } = e;
|
|
@@ -648,14 +648,14 @@ function et(e) {
|
|
|
648
648
|
//#endregion
|
|
649
649
|
//#region ../../libraries/react-collection/dist/widgets/richTextWidget/RichTextWidget.cssm.js
|
|
650
650
|
var tt = "_1vx76w30", nt = "_1vx76w33", rt = "_1vx76w34", it = { style: u({ baseSpacing: ".875rem" }) }, at = (r) => {
|
|
651
|
-
let a =
|
|
651
|
+
let a = v(58), { field: o } = r, [s, c] = T(!1), { key: u, label: f, helper_text: p, readonly: m, placeholder: h } = o, g = u === void 0 ? "" : u, b = f === void 0 ? "" : f, C = p === void 0 ? "" : p, E = m === void 0 ? !1 : m, D;
|
|
652
652
|
a[0] === o ? D = a[1] : (D = t(o), a[0] = o, a[1] = D);
|
|
653
653
|
let O;
|
|
654
654
|
a[2] !== g || a[3] !== D ? (O = {
|
|
655
655
|
name: g,
|
|
656
656
|
rules: D
|
|
657
657
|
}, a[2] = g, a[3] = D, a[4] = O) : O = a[4];
|
|
658
|
-
let { field: ee, fieldState: te } =
|
|
658
|
+
let { field: ee, fieldState: te } = _(O), { value: k, onBlur: A, onChange: j, disabled: M } = ee, ne = h || "Write something ...", N;
|
|
659
659
|
a[5] === ne ? N = a[6] : (N = _e({ placeholder: ne }), a[5] = ne, a[6] = N);
|
|
660
660
|
let P = k || "", F = !M && !E, I;
|
|
661
661
|
a[7] === Symbol.for("react.memo_cache_sentinel") ? (I = { attributes: {
|
|
@@ -683,7 +683,7 @@ var tt = "_1vx76w30", nt = "_1vx76w33", rt = "_1vx76w34", it = { style: u({ base
|
|
|
683
683
|
z?.commands && !s && (z.commands.setContent(k || "", { emitUpdate: !1 }), c(!0));
|
|
684
684
|
}, a[15] = z, a[16] = s, a[17] = k, a[18] = B) : B = a[18];
|
|
685
685
|
let re;
|
|
686
|
-
a[19] === k ? re = a[20] : (re = [k], a[19] = k, a[20] = re),
|
|
686
|
+
a[19] === k ? re = a[20] : (re = [k], a[19] = k, a[20] = re), w(B, re);
|
|
687
687
|
let V, H;
|
|
688
688
|
a[21] !== M || a[22] !== z || a[23] !== E ? (V = () => {
|
|
689
689
|
z && z.setEditable(!M && !E, !1);
|
|
@@ -691,30 +691,30 @@ var tt = "_1vx76w30", nt = "_1vx76w33", rt = "_1vx76w34", it = { style: u({ base
|
|
|
691
691
|
z,
|
|
692
692
|
M,
|
|
693
693
|
E
|
|
694
|
-
], a[21] = M, a[22] = z, a[23] = E, a[24] = V, a[25] = H) : (V = a[24], H = a[25]),
|
|
694
|
+
], a[21] = M, a[22] = z, a[23] = E, a[24] = V, a[25] = H) : (V = a[24], H = a[25]), w(V, H);
|
|
695
695
|
let U, W;
|
|
696
696
|
a[26] !== z || a[27] !== A ? (U = () => {
|
|
697
697
|
if (z) return z.on("blur", A), () => {
|
|
698
698
|
z.off("blur", A);
|
|
699
699
|
};
|
|
700
|
-
}, W = [z, A], a[26] = z, a[27] = A, a[28] = U, a[29] = W) : (U = a[28], W = a[29]),
|
|
700
|
+
}, W = [z, A], a[26] = z, a[27] = A, a[28] = U, a[29] = W) : (U = a[28], W = a[29]), w(U, W);
|
|
701
701
|
let G = te?.error?.message, K = !!o?.required, q = M && "_1vx76w31", J = E && "_1vx76w32", Y;
|
|
702
|
-
a[30] !== q || a[31] !== J ? (Y =
|
|
702
|
+
a[30] !== q || a[31] !== J ? (Y = y(tt, q, J), a[30] = q, a[31] = J, a[32] = Y) : Y = a[32];
|
|
703
703
|
let X;
|
|
704
704
|
a[33] === z ? X = a[34] : (X = { editor: z }, a[33] = z, a[34] = X);
|
|
705
705
|
let Z, ie;
|
|
706
|
-
a[35] === Symbol.for("react.memo_cache_sentinel") ? (Z = /* @__PURE__ */
|
|
706
|
+
a[35] === Symbol.for("react.memo_cache_sentinel") ? (Z = /* @__PURE__ */ x(Ze, {}), ie = /* @__PURE__ */ x(e, { orientation: "horizontal" }), a[35] = Z, a[36] = ie) : (Z = a[35], ie = a[36]);
|
|
707
707
|
let Q;
|
|
708
708
|
a[37] === z?.commands ? Q = a[38] : (Q = () => z?.commands.focus(), a[37] = z?.commands, a[38] = Q);
|
|
709
709
|
let ae;
|
|
710
|
-
a[39] === z ? ae = a[40] : (ae = /* @__PURE__ */
|
|
710
|
+
a[39] === z ? ae = a[40] : (ae = /* @__PURE__ */ x(fe, { editor: z }), a[39] = z, a[40] = ae);
|
|
711
711
|
let oe;
|
|
712
|
-
a[41] !== Q || a[42] !== ae ? (oe = /* @__PURE__ */
|
|
712
|
+
a[41] !== Q || a[42] !== ae ? (oe = /* @__PURE__ */ S("div", {
|
|
713
713
|
className: nt,
|
|
714
714
|
children: [
|
|
715
715
|
Z,
|
|
716
716
|
ie,
|
|
717
|
-
/* @__PURE__ */
|
|
717
|
+
/* @__PURE__ */ x("div", {
|
|
718
718
|
className: rt,
|
|
719
719
|
onClick: Q,
|
|
720
720
|
children: ae
|
|
@@ -722,28 +722,28 @@ var tt = "_1vx76w30", nt = "_1vx76w33", rt = "_1vx76w34", it = { style: u({ base
|
|
|
722
722
|
]
|
|
723
723
|
}), a[41] = Q, a[42] = ae, a[43] = oe) : oe = a[43];
|
|
724
724
|
let se;
|
|
725
|
-
a[44] !== X || a[45] !== oe ? (se = /* @__PURE__ */
|
|
725
|
+
a[44] !== X || a[45] !== oe ? (se = /* @__PURE__ */ x(d, {
|
|
726
726
|
theme: it,
|
|
727
|
-
children: /* @__PURE__ */
|
|
727
|
+
children: /* @__PURE__ */ x(i, { children: /* @__PURE__ */ x(pe.Provider, {
|
|
728
728
|
value: X,
|
|
729
729
|
children: oe
|
|
730
730
|
}) })
|
|
731
731
|
}), a[44] = X, a[45] = oe, a[46] = se) : se = a[46];
|
|
732
732
|
let ce;
|
|
733
|
-
a[47] !== Y || a[48] !== se ? (ce = /* @__PURE__ */
|
|
733
|
+
a[47] !== Y || a[48] !== se ? (ce = /* @__PURE__ */ x("div", {
|
|
734
734
|
className: Y,
|
|
735
735
|
children: se
|
|
736
736
|
}), a[47] = Y, a[48] = se, a[49] = ce) : ce = a[49];
|
|
737
737
|
let le;
|
|
738
|
-
return a[50] !== C || a[51] !== g || a[52] !==
|
|
738
|
+
return a[50] !== C || a[51] !== g || a[52] !== b || a[53] !== E || a[54] !== G || a[55] !== K || a[56] !== ce ? (le = /* @__PURE__ */ x(n, {
|
|
739
739
|
error: G,
|
|
740
740
|
helperText: C,
|
|
741
741
|
readOnly: E,
|
|
742
|
-
label:
|
|
742
|
+
label: b,
|
|
743
743
|
htmlFor: g,
|
|
744
744
|
isRequired: K,
|
|
745
745
|
children: ce
|
|
746
|
-
}), a[50] = C, a[51] = g, a[52] =
|
|
746
|
+
}), a[50] = C, a[51] = g, a[52] = b, a[53] = E, a[54] = G, a[55] = K, a[56] = ce, a[57] = le) : le = a[57], le;
|
|
747
747
|
};
|
|
748
748
|
//#endregion
|
|
749
749
|
export { at as RichTextWidget, at as default };
|