@uva-glass/component-library 3.55.2 → 3.55.3
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/{Lexical.prod-DCGjHGxG.js → Lexical.prod-DIglXatJ.js} +958 -947
- package/dist/Lexical.prod-DIglXatJ.js.map +1 -0
- package/dist/LexicalClipboard.prod-Bnzu0sh_.js +248 -0
- package/dist/{LexicalClipboard.prod-CGG14aoP.js.map → LexicalClipboard.prod-Bnzu0sh_.js.map} +1 -1
- package/dist/{LexicalExtension.prod-DWt1IjPF.js → LexicalExtension.prod-COPHoPpX.js} +320 -288
- package/dist/LexicalExtension.prod-COPHoPpX.js.map +1 -0
- package/dist/{LexicalLink.prod-Dy1gE75H.js → LexicalLink.prod-Bf9JUdMv.js} +216 -198
- package/dist/LexicalLink.prod-Bf9JUdMv.js.map +1 -0
- package/dist/{LexicalList.prod-D9R0L7cu.js → LexicalList.prod-DRz8vsM9.js} +247 -241
- package/dist/LexicalList.prod-DRz8vsM9.js.map +1 -0
- package/dist/{LexicalTable.prod-C2FP47Lm.js → LexicalTable.prod-D16GW-aZ.js} +741 -729
- package/dist/LexicalTable.prod-D16GW-aZ.js.map +1 -0
- package/dist/LexicalUtils.prod-BBTLliac.js +360 -0
- package/dist/LexicalUtils.prod-BBTLliac.js.map +1 -0
- package/dist/{LinkContextMenu-DZlKfbg1.js → LinkContextMenu-m_CGQEiX.js} +2 -2
- package/dist/{LinkContextMenu-DZlKfbg1.js.map → LinkContextMenu-m_CGQEiX.js.map} +1 -1
- package/dist/{PasteHandlerPlugin-DUdocSHB.js → PasteHandlerPlugin-DjD1wryY.js} +4 -4
- package/dist/{PasteHandlerPlugin-DUdocSHB.js.map → PasteHandlerPlugin-DjD1wryY.js.map} +1 -1
- package/dist/{TableCellResizerPlugin-BGolbi44.js → TableCellResizerPlugin-CgYsYsuY.js} +41 -41
- package/dist/{TableCellResizerPlugin-BGolbi44.js.map → TableCellResizerPlugin-CgYsYsuY.js.map} +1 -1
- package/dist/{chunk-OPOZOKLO-CXKdjnjn.js → chunk-SZQXB3JV-D0XG4Tlp.js} +5 -5
- package/dist/chunk-SZQXB3JV-D0XG4Tlp.js.map +1 -0
- package/dist/{client-C0JVBgoR.js → client-UU-mS47K.js} +6 -6
- package/dist/{client-C0JVBgoR.js.map → client-UU-mS47K.js.map} +1 -1
- package/dist/components/Accordion/Accordion.test.js +4 -4
- package/dist/components/AccordionCard/AccordionCard.test.js +4 -4
- package/dist/components/ActionList/ActionList.test.js +4 -4
- package/dist/components/AppStatusBar/AppStatusBar.test.js +3 -3
- package/dist/components/Attention/Attention.test.js +3 -3
- package/dist/components/Backdrop/Backdrop.test.js +3 -3
- package/dist/components/Buttons/Button.stories.js +1 -1
- package/dist/components/Buttons/Button.test.js +3 -3
- package/dist/components/Buttons/LinkButton.stories.js +1 -1
- package/dist/components/Buttons/LinkButton.test.js +3 -3
- package/dist/components/Buttons/MenuButton.stories.js +1 -1
- package/dist/components/Buttons/MenuButton.test.js +3 -3
- package/dist/components/Card/Card.test.js +3 -3
- package/dist/components/Checkbox/Checkbox.stories.js +1 -1
- package/dist/components/Checkbox/Checkbox.test.js +4 -4
- package/dist/components/CheckboxButtonBar/CheckboxButtonBar.stories.js +1 -1
- package/dist/components/CheckboxButtonBar/CheckboxButtonBar.test.js +3 -3
- package/dist/components/CheckboxTree/CheckboxTree.js +2 -2
- package/dist/components/CheckboxTree/CheckboxTree.stories.js +4 -4
- package/dist/components/CheckboxTree/index.js +2 -2
- package/dist/components/Chip/Chip.stories.js +1 -1
- package/dist/components/ControlsButton/ControlsButton.stories.js +1 -1
- package/dist/components/Drawer/Drawer.stories.js +1 -1
- package/dist/components/FeedbackBar/FeedbackBar.test.js +3 -3
- package/dist/components/FormInput/FormInput.js +2 -2
- package/dist/components/FormInput/FormInput.stories.js +3 -3
- package/dist/components/FormInput/index.js +2 -2
- package/dist/components/IconButton/IconButton.stories.js +1 -1
- package/dist/components/InputField/InputField.stories.js +3 -3
- package/dist/components/Label/Label.test.js +3 -3
- package/dist/components/MetaDataBar/MetaDataBar.test.js +2 -2
- package/dist/components/ModalDialog/ModalDialog.stories.js +1 -1
- package/dist/components/MultiSelect/MultiSelect.js +2 -2
- package/dist/components/MultiSelect/MultiSelect.stories.js +3 -3
- package/dist/components/MultiSelect/components/MultiSelectHeader.js +2 -2
- package/dist/components/MultiSelect/index.js +2 -2
- package/dist/components/MultiSelectBox/MultiSelectBox.stories.js +1 -1
- package/dist/components/MultiSelectBox/MultiSelectBox.test.js +3 -3
- package/dist/components/Notification/Notification.stories.js +1 -1
- package/dist/components/Notification/Notification.test.js +3 -3
- package/dist/components/OverlayCloseButton/OverlayCloseButton.stories.js +1 -1
- package/dist/components/PeriodSelector/PeriodSelector.js +2 -2
- package/dist/components/PeriodSelector/PeriodSelector.stories.js +3 -3
- package/dist/components/PeriodSelector/index.js +2 -2
- package/dist/components/ProgrammeCard/ProgrammeCard.stories.js +2 -2
- package/dist/components/RadioGroup/RadioGroup.stories.js +1 -1
- package/dist/components/RadioGroup/Radiogroup.test.js +3 -3
- package/dist/components/RadioTabSelector/RadioTabSelector.js +2 -2
- package/dist/components/RadioTabSelector/RadioTabSelector.stories.js +3 -3
- package/dist/components/RadioTabSelector/index.js +2 -2
- package/dist/components/RteEditor/EditorHeader/EditorHeader.js +2 -2
- package/dist/components/RteEditor/EditorHeader/index.js +2 -2
- package/dist/components/RteEditor/Plugins/BlockFormatPlugin/BlockFormatPlugin.js +3 -3
- package/dist/components/RteEditor/Plugins/CourseCataloguePlugin/CourseCataloguePlugin.js +32 -32
- package/dist/components/RteEditor/Plugins/HistoryPlugin/HistoryPlugin.js +2 -2
- package/dist/components/RteEditor/Plugins/HistoryPlugin/index.js +2 -2
- package/dist/components/RteEditor/Plugins/LinkPlugin/AddLinkForm/AddLinkFrom.js +2 -2
- package/dist/components/RteEditor/Plugins/LinkPlugin/LinkContextMenu/LinkContextMenu.js +1 -1
- package/dist/components/RteEditor/Plugins/LinkPlugin/LinkPlugin.js +2 -2
- package/dist/components/RteEditor/Plugins/LinkPlugin/helpers.js +1 -1
- package/dist/components/RteEditor/Plugins/LinkPlugin/index.js +2 -2
- package/dist/components/RteEditor/Plugins/ListPlugin/ListPlugin.js +15 -15
- package/dist/components/RteEditor/Plugins/PasteHandlerPlugin/PasteHandlerPlugin.js +1 -1
- package/dist/components/RteEditor/Plugins/PasteHandlerPlugin/index.js +1 -1
- package/dist/components/RteEditor/Plugins/TableCellResizerPlugin/TableCellResizerPlugin.js +1 -1
- package/dist/components/RteEditor/Plugins/TableCellResizerPlugin/index.js +1 -1
- package/dist/components/RteEditor/Plugins/TablePlugin/AddTableFrom.js +2 -2
- package/dist/components/RteEditor/Plugins/TablePlugin/TablePlugin.js +2 -2
- package/dist/components/RteEditor/Plugins/TablePlugin/helpers.js +32 -32
- package/dist/components/RteEditor/Plugins/TablePlugin/index.js +2 -2
- package/dist/components/RteEditor/Plugins/ToolbarPlugin/ToolbarPlugin.js +2 -2
- package/dist/components/RteEditor/Plugins/ToolbarPlugin/index.js +2 -2
- package/dist/components/RteEditor/Plugins/index.js +3 -3
- package/dist/components/RteEditor/RteEditor.js +2 -2
- package/dist/components/RteEditor/RteEditor.stories.js +2 -2
- package/dist/components/RteEditor/helpers.js +4 -4
- package/dist/components/RteEditor/index.js +2 -2
- package/dist/components/RteEditor/nodes/CourseCatalogueNode/CourseCatalogueNode.js +17 -17
- package/dist/components/RteEditor/nodes/TableWrapperNode/TableWrapperNode.js +13 -13
- package/dist/components/SelectListbox/SelectListBox.stories.js +1 -1
- package/dist/components/Sortable/Sortable.stories.js +1 -1
- package/dist/components/StatusBadge/StatusBadge.test.js +3 -3
- package/dist/components/TextArea/TextArea.stories.js +1 -1
- package/dist/components/TextArea/TextArea.test.js +4 -4
- package/dist/components/ToggleSwitch/ToggleSwitch.stories.js +1 -1
- package/dist/components/VarIndicator/VarIndicator.stories.js +1 -1
- package/dist/components/VarIndicator/VarIndicator.test.js +4 -4
- package/dist/components/index.js +2 -2
- package/dist/{components-DVUYdcHS.js → components-C4MCdrDH.js} +456 -453
- package/dist/components-C4MCdrDH.js.map +1 -0
- package/dist/{dist-D6qYwmKD.js → dist-2TKCXdYZ.js} +315 -315
- package/dist/{dist-D6qYwmKD.js.map → dist-2TKCXdYZ.js.map} +1 -1
- package/dist/{esm-Cmy7DlsJ.js → esm-UNe_gmRA.js} +2 -2
- package/dist/{esm-Cmy7DlsJ.js.map → esm-UNe_gmRA.js.map} +1 -1
- package/dist/{helpers-DcFTH1J1.js → helpers-BBSxTGRl.js} +7 -7
- package/dist/{helpers-DcFTH1J1.js.map → helpers-BBSxTGRl.js.map} +1 -1
- package/dist/index.js +2 -2
- package/dist/{react-18-PI4Gvl2f.js → react-18-CRbkdI-3.js} +2 -2
- package/dist/{react-18-PI4Gvl2f.js.map → react-18-CRbkdI-3.js.map} +1 -1
- package/dist/{react.esm-Cev8dB-E.js → react.esm-CzIhAqlo.js} +479 -479
- package/dist/{react.esm-Cev8dB-E.js.map → react.esm-CzIhAqlo.js.map} +1 -1
- package/dist/setupTests.js +1 -1
- package/dist/storybook__react.d.js +3 -3
- package/dist/{test-CPFNM-bL.js → test-DQruvi8i.js} +3704 -5824
- package/dist/test-DQruvi8i.js.map +1 -0
- package/package.json +16 -16
- package/dist/Lexical.prod-DCGjHGxG.js.map +0 -1
- package/dist/LexicalClipboard.prod-CGG14aoP.js +0 -248
- package/dist/LexicalExtension.prod-DWt1IjPF.js.map +0 -1
- package/dist/LexicalLink.prod-Dy1gE75H.js.map +0 -1
- package/dist/LexicalList.prod-D9R0L7cu.js.map +0 -1
- package/dist/LexicalTable.prod-C2FP47Lm.js.map +0 -1
- package/dist/LexicalUtils.prod-BzrjMu6t.js +0 -242
- package/dist/LexicalUtils.prod-BzrjMu6t.js.map +0 -1
- package/dist/chunk-OPOZOKLO-CXKdjnjn.js.map +0 -1
- package/dist/components-DVUYdcHS.js.map +0 -1
- package/dist/test-CPFNM-bL.js.map +0 -1
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { A as e,
|
|
2
|
-
import {
|
|
1
|
+
import { A as e, B as t, C as n, Cn as r, D as i, Dt as a, Fn as o, Ht as s, M as c, Mt as ee, N as te, Nn as l, Ot as ne, P as re, St as u, Tt as ie, Un as d, Vn as ae, Vt as f, W as p, Wn as oe, Xt as se, Z as m, _ as ce, b as le, cn as ue, dn as de, et as fe, fn as pe, g as me, gn as he, it as ge, ln as _e, mn as ve, on as ye, ot as h, p as be, r as g, t as xe, ut as Se, w as _, y as Ce, yt as we } from "./Lexical.prod-DIglXatJ.js";
|
|
2
|
+
import { c as Te, n as Ee, t as De, u as Oe } from "./LexicalUtils.prod-BBTLliac.js";
|
|
3
3
|
//#region node_modules/@lexical/extension/LexicalExtension.prod.mjs
|
|
4
|
-
var
|
|
5
|
-
function
|
|
6
|
-
if (
|
|
4
|
+
var ke = Symbol.for("preact-signals");
|
|
5
|
+
function v() {
|
|
6
|
+
if (C > 1) return void C--;
|
|
7
7
|
let e, t = !1;
|
|
8
|
-
for (;
|
|
9
|
-
let n =
|
|
10
|
-
for (
|
|
8
|
+
for (; x !== void 0;) {
|
|
9
|
+
let n = x;
|
|
10
|
+
for (x = void 0, w++; n !== void 0;) {
|
|
11
11
|
let r = n.o;
|
|
12
|
-
if (n.o = void 0, n.f &= -3, !(8 & n.f) &&
|
|
12
|
+
if (n.o = void 0, n.f &= -3, !(8 & n.f) && k(n)) try {
|
|
13
13
|
n.c();
|
|
14
14
|
} catch (n) {
|
|
15
15
|
t ||= (e = n, !0);
|
|
@@ -17,53 +17,53 @@ function y() {
|
|
|
17
17
|
n = r;
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
|
-
if (
|
|
20
|
+
if (w = 0, C--, t) throw e;
|
|
21
21
|
}
|
|
22
|
-
function
|
|
23
|
-
if (
|
|
24
|
-
|
|
22
|
+
function y(e) {
|
|
23
|
+
if (C > 0) return e();
|
|
24
|
+
C++;
|
|
25
25
|
try {
|
|
26
26
|
return e();
|
|
27
27
|
} finally {
|
|
28
|
-
|
|
28
|
+
v();
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
|
-
var
|
|
32
|
-
function
|
|
33
|
-
let t =
|
|
34
|
-
|
|
31
|
+
var b, x;
|
|
32
|
+
function S(e) {
|
|
33
|
+
let t = b;
|
|
34
|
+
b = void 0;
|
|
35
35
|
try {
|
|
36
36
|
return e();
|
|
37
37
|
} finally {
|
|
38
|
-
|
|
38
|
+
b = t;
|
|
39
39
|
}
|
|
40
40
|
}
|
|
41
|
-
var
|
|
42
|
-
function
|
|
43
|
-
if (
|
|
41
|
+
var C = 0, w = 0, T = 0;
|
|
42
|
+
function E(e) {
|
|
43
|
+
if (b === void 0) return;
|
|
44
44
|
let t = e.n;
|
|
45
|
-
return t === void 0 || t.t !==
|
|
45
|
+
return t === void 0 || t.t !== b ? (t = {
|
|
46
46
|
i: 0,
|
|
47
47
|
S: e,
|
|
48
|
-
p:
|
|
48
|
+
p: b.s,
|
|
49
49
|
n: void 0,
|
|
50
|
-
t:
|
|
50
|
+
t: b,
|
|
51
51
|
e: void 0,
|
|
52
52
|
x: void 0,
|
|
53
53
|
r: t
|
|
54
|
-
},
|
|
54
|
+
}, b.s !== void 0 && (b.s.n = t), b.s = t, e.n = t, 32 & b.f && e.S(t), t) : t.i === -1 ? (t.i = 0, t.n !== void 0 && (t.n.p = t.p, t.p !== void 0 && (t.p.n = t.n), t.p = b.s, t.n = void 0, b.s.n = t, b.s = t), t) : void 0;
|
|
55
55
|
}
|
|
56
|
-
function
|
|
56
|
+
function D(e, t) {
|
|
57
57
|
this.v = e, this.i = 0, this.n = void 0, this.t = void 0, this.W = t?.watched, this.Z = t?.unwatched, this.name = t?.name;
|
|
58
58
|
}
|
|
59
|
-
function
|
|
60
|
-
return new
|
|
59
|
+
function O(e, t) {
|
|
60
|
+
return new D(e, t);
|
|
61
61
|
}
|
|
62
|
-
function
|
|
62
|
+
function k(e) {
|
|
63
63
|
for (let t = e.s; t !== void 0; t = t.n) if (t.S.i !== t.i || !t.S.h() || t.S.i !== t.i) return !0;
|
|
64
64
|
return !1;
|
|
65
65
|
}
|
|
66
|
-
function
|
|
66
|
+
function A(e) {
|
|
67
67
|
for (let t = e.s; t !== void 0; t = t.n) {
|
|
68
68
|
let n = t.S.n;
|
|
69
69
|
if (n !== void 0 && (t.r = n), t.S.n = t, t.i = -1, t.n === void 0) {
|
|
@@ -72,7 +72,7 @@ function j(e) {
|
|
|
72
72
|
}
|
|
73
73
|
}
|
|
74
74
|
}
|
|
75
|
-
function
|
|
75
|
+
function j(e) {
|
|
76
76
|
let t, n = e.s;
|
|
77
77
|
for (; n !== void 0;) {
|
|
78
78
|
let e = n.p;
|
|
@@ -80,40 +80,40 @@ function M(e) {
|
|
|
80
80
|
}
|
|
81
81
|
e.s = t;
|
|
82
82
|
}
|
|
83
|
-
function
|
|
84
|
-
|
|
83
|
+
function M(e, t) {
|
|
84
|
+
D.call(this, void 0), this.x = e, this.s = void 0, this.g = T - 1, this.f = 4, this.W = t?.watched, this.Z = t?.unwatched, this.name = t?.name;
|
|
85
85
|
}
|
|
86
|
-
function
|
|
87
|
-
return new
|
|
86
|
+
function Ae(e, t) {
|
|
87
|
+
return new M(e, t);
|
|
88
88
|
}
|
|
89
|
-
function
|
|
89
|
+
function je(e) {
|
|
90
90
|
let t = e.u;
|
|
91
91
|
if (e.u = void 0, typeof t == "function") {
|
|
92
|
-
|
|
93
|
-
let n =
|
|
94
|
-
|
|
92
|
+
C++;
|
|
93
|
+
let n = b;
|
|
94
|
+
b = void 0;
|
|
95
95
|
try {
|
|
96
96
|
t();
|
|
97
97
|
} catch (t) {
|
|
98
|
-
throw e.f &= -2, e.f |= 8,
|
|
98
|
+
throw e.f &= -2, e.f |= 8, N(e), t;
|
|
99
99
|
} finally {
|
|
100
|
-
|
|
100
|
+
b = n, v();
|
|
101
101
|
}
|
|
102
102
|
}
|
|
103
103
|
}
|
|
104
|
-
function
|
|
104
|
+
function N(e) {
|
|
105
105
|
for (let t = e.s; t !== void 0; t = t.n) t.S.U(t);
|
|
106
|
-
e.x = void 0, e.s = void 0,
|
|
106
|
+
e.x = void 0, e.s = void 0, je(e);
|
|
107
107
|
}
|
|
108
|
-
function
|
|
109
|
-
if (
|
|
110
|
-
|
|
108
|
+
function Me(e) {
|
|
109
|
+
if (b !== this) throw Error("Out-of-order effect");
|
|
110
|
+
j(this), b = e, this.f &= -2, 8 & this.f && N(this), v();
|
|
111
111
|
}
|
|
112
|
-
function
|
|
112
|
+
function P(e, t) {
|
|
113
113
|
this.x = e, this.u = void 0, this.s = void 0, this.o = void 0, this.f = 32, this.name = t?.name;
|
|
114
114
|
}
|
|
115
|
-
function
|
|
116
|
-
let n = new
|
|
115
|
+
function F(e, t) {
|
|
116
|
+
let n = new P(e, t);
|
|
117
117
|
try {
|
|
118
118
|
n.c();
|
|
119
119
|
} catch (e) {
|
|
@@ -122,105 +122,105 @@ function L(e, t) {
|
|
|
122
122
|
let r = n.d.bind(n);
|
|
123
123
|
return r[Symbol.dispose] = r, r;
|
|
124
124
|
}
|
|
125
|
-
function
|
|
125
|
+
function I(e, t = {}) {
|
|
126
126
|
let n = {};
|
|
127
127
|
for (let r in e) {
|
|
128
128
|
let i = t[r];
|
|
129
|
-
n[r] =
|
|
129
|
+
n[r] = O(i === void 0 ? e[r] : i);
|
|
130
130
|
}
|
|
131
131
|
return n;
|
|
132
132
|
}
|
|
133
|
-
|
|
133
|
+
D.prototype.brand = ke, D.prototype.h = function() {
|
|
134
134
|
return !0;
|
|
135
|
-
},
|
|
135
|
+
}, D.prototype.S = function(e) {
|
|
136
136
|
let t = this.t;
|
|
137
|
-
t !== e && e.e === void 0 && (e.x = t, this.t = e, t === void 0 ?
|
|
137
|
+
t !== e && e.e === void 0 && (e.x = t, this.t = e, t === void 0 ? S(() => {
|
|
138
138
|
var e;
|
|
139
139
|
(e = this.W) == null || e.call(this);
|
|
140
140
|
}) : t.e = e);
|
|
141
|
-
},
|
|
141
|
+
}, D.prototype.U = function(e) {
|
|
142
142
|
if (this.t !== void 0) {
|
|
143
143
|
let t = e.e, n = e.x;
|
|
144
|
-
t !== void 0 && (t.x = n, e.e = void 0), n !== void 0 && (n.e = t, e.x = void 0), e === this.t && (this.t = n, n === void 0 &&
|
|
144
|
+
t !== void 0 && (t.x = n, e.e = void 0), n !== void 0 && (n.e = t, e.x = void 0), e === this.t && (this.t = n, n === void 0 && S(() => {
|
|
145
145
|
var e;
|
|
146
146
|
(e = this.Z) == null || e.call(this);
|
|
147
147
|
}));
|
|
148
148
|
}
|
|
149
|
-
},
|
|
150
|
-
return
|
|
151
|
-
let t = this.value, n =
|
|
152
|
-
|
|
149
|
+
}, D.prototype.subscribe = function(e) {
|
|
150
|
+
return F(() => {
|
|
151
|
+
let t = this.value, n = b;
|
|
152
|
+
b = void 0;
|
|
153
153
|
try {
|
|
154
154
|
e(t);
|
|
155
155
|
} finally {
|
|
156
|
-
|
|
156
|
+
b = n;
|
|
157
157
|
}
|
|
158
158
|
}, { name: "sub" });
|
|
159
|
-
},
|
|
159
|
+
}, D.prototype.valueOf = function() {
|
|
160
160
|
return this.value;
|
|
161
|
-
},
|
|
161
|
+
}, D.prototype.toString = function() {
|
|
162
162
|
return this.value + "";
|
|
163
|
-
},
|
|
163
|
+
}, D.prototype.toJSON = function() {
|
|
164
164
|
return this.value;
|
|
165
|
-
},
|
|
166
|
-
let e =
|
|
167
|
-
|
|
165
|
+
}, D.prototype.peek = function() {
|
|
166
|
+
let e = b;
|
|
167
|
+
b = void 0;
|
|
168
168
|
try {
|
|
169
169
|
return this.value;
|
|
170
170
|
} finally {
|
|
171
|
-
|
|
171
|
+
b = e;
|
|
172
172
|
}
|
|
173
|
-
}, Object.defineProperty(
|
|
173
|
+
}, Object.defineProperty(D.prototype, "value", {
|
|
174
174
|
get() {
|
|
175
|
-
let e =
|
|
175
|
+
let e = E(this);
|
|
176
176
|
return e !== void 0 && (e.i = this.i), this.v;
|
|
177
177
|
},
|
|
178
178
|
set(e) {
|
|
179
179
|
if (e !== this.v) {
|
|
180
|
-
if (
|
|
181
|
-
this.v = e, this.i++,
|
|
180
|
+
if (w > 100) throw Error("Cycle detected");
|
|
181
|
+
this.v = e, this.i++, T++, C++;
|
|
182
182
|
try {
|
|
183
183
|
for (let e = this.t; e !== void 0; e = e.x) e.t.N();
|
|
184
184
|
} finally {
|
|
185
|
-
|
|
185
|
+
v();
|
|
186
186
|
}
|
|
187
187
|
}
|
|
188
188
|
}
|
|
189
|
-
}),
|
|
189
|
+
}), M.prototype = new D(), M.prototype.h = function() {
|
|
190
190
|
if (this.f &= -3, 1 & this.f) return !1;
|
|
191
|
-
if ((36 & this.f) == 32 || (this.f &= -5, this.g ===
|
|
192
|
-
if (this.g =
|
|
193
|
-
let e =
|
|
191
|
+
if ((36 & this.f) == 32 || (this.f &= -5, this.g === T)) return !0;
|
|
192
|
+
if (this.g = T, this.f |= 1, this.i > 0 && !k(this)) return this.f &= -2, !0;
|
|
193
|
+
let e = b;
|
|
194
194
|
try {
|
|
195
|
-
|
|
195
|
+
A(this), b = this;
|
|
196
196
|
let e = this.x();
|
|
197
197
|
(16 & this.f || this.v !== e || this.i === 0) && (this.v = e, this.f &= -17, this.i++);
|
|
198
198
|
} catch (e) {
|
|
199
199
|
this.v = e, this.f |= 16, this.i++;
|
|
200
200
|
}
|
|
201
|
-
return
|
|
202
|
-
},
|
|
201
|
+
return b = e, j(this), this.f &= -2, !0;
|
|
202
|
+
}, M.prototype.S = function(e) {
|
|
203
203
|
if (this.t === void 0) {
|
|
204
204
|
this.f |= 36;
|
|
205
205
|
for (let e = this.s; e !== void 0; e = e.n) e.S.S(e);
|
|
206
206
|
}
|
|
207
|
-
|
|
208
|
-
},
|
|
209
|
-
if (this.t !== void 0 && (
|
|
207
|
+
D.prototype.S.call(this, e);
|
|
208
|
+
}, M.prototype.U = function(e) {
|
|
209
|
+
if (this.t !== void 0 && (D.prototype.U.call(this, e), this.t === void 0)) {
|
|
210
210
|
this.f &= -33;
|
|
211
211
|
for (let e = this.s; e !== void 0; e = e.n) e.S.U(e);
|
|
212
212
|
}
|
|
213
|
-
},
|
|
213
|
+
}, M.prototype.N = function() {
|
|
214
214
|
if (!(2 & this.f)) {
|
|
215
215
|
this.f |= 6;
|
|
216
216
|
for (let e = this.t; e !== void 0; e = e.x) e.t.N();
|
|
217
217
|
}
|
|
218
|
-
}, Object.defineProperty(
|
|
218
|
+
}, Object.defineProperty(M.prototype, "value", { get() {
|
|
219
219
|
if (1 & this.f) throw Error("Cycle detected");
|
|
220
|
-
let e =
|
|
220
|
+
let e = E(this);
|
|
221
221
|
if (this.h(), e !== void 0 && (e.i = this.i), 16 & this.f) throw this.v;
|
|
222
222
|
return this.v;
|
|
223
|
-
} }),
|
|
223
|
+
} }), P.prototype.c = function() {
|
|
224
224
|
let e = this.S();
|
|
225
225
|
try {
|
|
226
226
|
if (8 & this.f || this.x === void 0) return;
|
|
@@ -229,27 +229,27 @@ O.prototype.brand = Te, O.prototype.h = function() {
|
|
|
229
229
|
} finally {
|
|
230
230
|
e();
|
|
231
231
|
}
|
|
232
|
-
},
|
|
232
|
+
}, P.prototype.S = function() {
|
|
233
233
|
if (1 & this.f) throw Error("Cycle detected");
|
|
234
|
-
this.f |= 1, this.f &= -9,
|
|
235
|
-
let e =
|
|
236
|
-
return
|
|
237
|
-
},
|
|
238
|
-
2 & this.f || (this.f |= 2, this.o =
|
|
239
|
-
},
|
|
240
|
-
this.f |= 8, 1 & this.f ||
|
|
241
|
-
},
|
|
234
|
+
this.f |= 1, this.f &= -9, je(this), A(this), C++;
|
|
235
|
+
let e = b;
|
|
236
|
+
return b = this, Me.bind(this, e);
|
|
237
|
+
}, P.prototype.N = function() {
|
|
238
|
+
2 & this.f || (this.f |= 2, this.o = x, x = this);
|
|
239
|
+
}, P.prototype.d = function() {
|
|
240
|
+
this.f |= 8, 1 & this.f || N(this);
|
|
241
|
+
}, P.prototype.dispose = function() {
|
|
242
242
|
this.d();
|
|
243
|
-
},
|
|
244
|
-
build: (e, t, n) =>
|
|
245
|
-
config:
|
|
243
|
+
}, e({
|
|
244
|
+
build: (e, t, n) => I(t),
|
|
245
|
+
config: h({
|
|
246
246
|
defaultSelection: "rootEnd",
|
|
247
247
|
disabled: !1
|
|
248
248
|
}),
|
|
249
249
|
name: "@lexical/extension/AutoFocus",
|
|
250
250
|
register(e, t, n) {
|
|
251
251
|
let r = n.getOutput();
|
|
252
|
-
return
|
|
252
|
+
return F(() => r.disabled.value ? void 0 : e.registerRootListener((t) => {
|
|
253
253
|
e.focus(() => {
|
|
254
254
|
let e = document.activeElement;
|
|
255
255
|
t === null || e !== null && t.contains(e) || t.focus({ preventScroll: !0 });
|
|
@@ -257,50 +257,50 @@ O.prototype.brand = Te, O.prototype.h = function() {
|
|
|
257
257
|
}));
|
|
258
258
|
}
|
|
259
259
|
});
|
|
260
|
-
function
|
|
261
|
-
let e =
|
|
262
|
-
e.clear(), e.append(n), t !== null && n.select(),
|
|
260
|
+
function Ne() {
|
|
261
|
+
let e = d(), t = g(), n = u();
|
|
262
|
+
e.clear(), e.append(n), t !== null && n.select(), l(t) && (t.format = 0);
|
|
263
263
|
}
|
|
264
|
-
function
|
|
265
|
-
return e.registerCommand(
|
|
264
|
+
function Pe(e, t = Ne) {
|
|
265
|
+
return e.registerCommand(xe, (n) => (e.update(t), !0), 0);
|
|
266
266
|
}
|
|
267
|
-
|
|
268
|
-
build: (e, t, n) =>
|
|
269
|
-
config:
|
|
267
|
+
e({
|
|
268
|
+
build: (e, t, n) => I(t),
|
|
269
|
+
config: h({ $onClear: Ne }),
|
|
270
270
|
name: "@lexical/extension/ClearEditor",
|
|
271
271
|
register(e, t, n) {
|
|
272
272
|
let { $onClear: r } = n.getOutput();
|
|
273
|
-
return
|
|
273
|
+
return F(() => Pe(e, r.value));
|
|
274
274
|
}
|
|
275
275
|
});
|
|
276
|
-
function
|
|
276
|
+
function Fe(e) {
|
|
277
277
|
return (typeof e.nodes == "function" ? e.nodes() : e.nodes) || [];
|
|
278
278
|
}
|
|
279
|
-
var
|
|
279
|
+
var L = se("format", { parse: (e) => typeof e == "number" ? e : 0 }), Ie = class extends _ {
|
|
280
280
|
$config() {
|
|
281
281
|
return this.config("decorator-text", {
|
|
282
|
-
extends:
|
|
282
|
+
extends: _,
|
|
283
283
|
stateConfigs: [{
|
|
284
284
|
flat: !0,
|
|
285
|
-
stateConfig:
|
|
285
|
+
stateConfig: L
|
|
286
286
|
}]
|
|
287
287
|
});
|
|
288
288
|
}
|
|
289
289
|
getFormat() {
|
|
290
|
-
return
|
|
290
|
+
return he(this, L);
|
|
291
291
|
}
|
|
292
292
|
getFormatFlags(e, t) {
|
|
293
|
-
return
|
|
293
|
+
return m(this.getFormat(), e, t);
|
|
294
294
|
}
|
|
295
295
|
hasFormat(e) {
|
|
296
|
-
let t =
|
|
296
|
+
let t = ae[e];
|
|
297
297
|
return (this.getFormat() & t) !== 0;
|
|
298
298
|
}
|
|
299
299
|
setFormat(e) {
|
|
300
|
-
return
|
|
300
|
+
return ue(this, L, e);
|
|
301
301
|
}
|
|
302
302
|
toggleFormat(e) {
|
|
303
|
-
let t =
|
|
303
|
+
let t = m(this.getFormat(), e, null);
|
|
304
304
|
return this.setFormat(t);
|
|
305
305
|
}
|
|
306
306
|
isInline() {
|
|
@@ -313,21 +313,21 @@ var z = re("format", { parse: (e) => typeof e == "number" ? e : 0 }), je = class
|
|
|
313
313
|
return !1;
|
|
314
314
|
}
|
|
315
315
|
};
|
|
316
|
-
function
|
|
317
|
-
return e instanceof
|
|
316
|
+
function Le(e) {
|
|
317
|
+
return e instanceof Ie;
|
|
318
318
|
}
|
|
319
|
-
|
|
319
|
+
e({
|
|
320
320
|
name: "@lexical/extension/DecoratorText",
|
|
321
|
-
nodes: () => [
|
|
321
|
+
nodes: () => [Ie],
|
|
322
322
|
register: (e, t, n) => e.registerCommand(_e, (e) => {
|
|
323
|
-
let t =
|
|
324
|
-
if (
|
|
323
|
+
let t = g();
|
|
324
|
+
if (fe(t) || l(t)) for (let n of t.getNodes()) Le(n) && n.toggleFormat(e);
|
|
325
325
|
return !1;
|
|
326
326
|
}, 1)
|
|
327
327
|
});
|
|
328
|
-
function
|
|
328
|
+
function Re(e, t) {
|
|
329
329
|
let n;
|
|
330
|
-
return
|
|
330
|
+
return O(e(), {
|
|
331
331
|
unwatched() {
|
|
332
332
|
n &&= (n(), void 0);
|
|
333
333
|
},
|
|
@@ -336,39 +336,39 @@ function Ne(e, t) {
|
|
|
336
336
|
}
|
|
337
337
|
});
|
|
338
338
|
}
|
|
339
|
-
var
|
|
340
|
-
build: (e) =>
|
|
339
|
+
var R = e({
|
|
340
|
+
build: (e) => Re(() => e.getEditorState(), (t) => e.registerUpdateListener((e) => {
|
|
341
341
|
t.value = e.editorState;
|
|
342
342
|
})),
|
|
343
343
|
name: "@lexical/extension/EditorState"
|
|
344
344
|
});
|
|
345
|
-
function
|
|
345
|
+
function z(e, ...t) {
|
|
346
346
|
let n = new URL("https://lexical.dev/docs/error"), r = new URLSearchParams();
|
|
347
347
|
r.append("code", e);
|
|
348
348
|
for (let e of t) r.append("v", e);
|
|
349
349
|
throw n.search = r.toString(), Error(`Minified Lexical error #${e}; visit ${n.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`);
|
|
350
350
|
}
|
|
351
|
-
function
|
|
351
|
+
function ze(e, t) {
|
|
352
352
|
if (e && t && !Array.isArray(t) && typeof e == "object" && typeof t == "object") {
|
|
353
353
|
let n = e, r = t;
|
|
354
|
-
for (let e in r) n[e] =
|
|
354
|
+
for (let e in r) n[e] = ze(n[e], r[e]);
|
|
355
355
|
return e;
|
|
356
356
|
}
|
|
357
357
|
return t;
|
|
358
358
|
}
|
|
359
|
-
var
|
|
360
|
-
function
|
|
361
|
-
return e.id ===
|
|
359
|
+
var B = 0, V = 1, Be = 2, H = 3, U = 4, W = 5, G = 6, K = 7;
|
|
360
|
+
function q(e) {
|
|
361
|
+
return e.id === B;
|
|
362
362
|
}
|
|
363
|
-
function
|
|
364
|
-
return e.id ===
|
|
363
|
+
function Ve(e) {
|
|
364
|
+
return e.id === Be;
|
|
365
365
|
}
|
|
366
|
-
function
|
|
366
|
+
function He(e) {
|
|
367
367
|
return function(e) {
|
|
368
|
-
return e.id ===
|
|
369
|
-
}(e) ||
|
|
368
|
+
return e.id === V;
|
|
369
|
+
}(e) || z(305, String(e.id), String(V)), Object.assign(e, { id: Be });
|
|
370
370
|
}
|
|
371
|
-
var
|
|
371
|
+
var Ue = /* @__PURE__ */ new Set(), We = class {
|
|
372
372
|
builder;
|
|
373
373
|
configs;
|
|
374
374
|
_dependency;
|
|
@@ -377,16 +377,16 @@ var Re = /* @__PURE__ */ new Set(), ze = class {
|
|
|
377
377
|
state;
|
|
378
378
|
_signal;
|
|
379
379
|
constructor(e, t) {
|
|
380
|
-
this.builder = e, this.extension = t, this.configs = /* @__PURE__ */ new Set(), this.state = { id:
|
|
380
|
+
this.builder = e, this.extension = t, this.configs = /* @__PURE__ */ new Set(), this.state = { id: B };
|
|
381
381
|
}
|
|
382
382
|
mergeConfigs() {
|
|
383
|
-
let e = this.extension.config || {}, t = this.extension.mergeConfig ? this.extension.mergeConfig.bind(this.extension) :
|
|
383
|
+
let e = this.extension.config || {}, t = this.extension.mergeConfig ? this.extension.mergeConfig.bind(this.extension) : ee;
|
|
384
384
|
for (let n of this.configs) e = t(e, n);
|
|
385
385
|
return e;
|
|
386
386
|
}
|
|
387
387
|
init(e) {
|
|
388
388
|
let t = this.state;
|
|
389
|
-
|
|
389
|
+
Ve(t) || z(306, String(t.id));
|
|
390
390
|
let n = {
|
|
391
391
|
getDependency: this.getInitDependency.bind(this),
|
|
392
392
|
getDirectDependentNames: this.getDirectDependentNames.bind(this),
|
|
@@ -400,13 +400,13 @@ var Re = /* @__PURE__ */ new Set(), ze = class {
|
|
|
400
400
|
}, i = function(e, t, n) {
|
|
401
401
|
return Object.assign(e, {
|
|
402
402
|
config: t,
|
|
403
|
-
id:
|
|
403
|
+
id: H,
|
|
404
404
|
registerState: n
|
|
405
405
|
});
|
|
406
406
|
}(t, this.mergeConfigs(), n), a;
|
|
407
407
|
this.state = i, this.extension.init && (a = this.extension.init(e, i.config, n)), this.state = function(e, t, n) {
|
|
408
408
|
return Object.assign(e, {
|
|
409
|
-
id:
|
|
409
|
+
id: U,
|
|
410
410
|
initResult: t,
|
|
411
411
|
registerState: n
|
|
412
412
|
});
|
|
@@ -414,7 +414,7 @@ var Re = /* @__PURE__ */ new Set(), ze = class {
|
|
|
414
414
|
}
|
|
415
415
|
build(e) {
|
|
416
416
|
let t = this.state, n;
|
|
417
|
-
t.id !==
|
|
417
|
+
t.id !== U && z(307, String(t.id), String(W)), this.extension.build && (n = this.extension.build(e, t.config, t.registerState));
|
|
418
418
|
let r = {
|
|
419
419
|
...t.registerState,
|
|
420
420
|
getOutput: () => n,
|
|
@@ -422,7 +422,7 @@ var Re = /* @__PURE__ */ new Set(), ze = class {
|
|
|
422
422
|
};
|
|
423
423
|
this.state = function(e, t, n) {
|
|
424
424
|
return Object.assign(e, {
|
|
425
|
-
id:
|
|
425
|
+
id: W,
|
|
426
426
|
output: t,
|
|
427
427
|
registerState: n
|
|
428
428
|
});
|
|
@@ -431,32 +431,32 @@ var Re = /* @__PURE__ */ new Set(), ze = class {
|
|
|
431
431
|
register(e, t) {
|
|
432
432
|
this._signal = t;
|
|
433
433
|
let n = this.state;
|
|
434
|
-
n.id !==
|
|
434
|
+
n.id !== W && z(308, String(n.id), String(W));
|
|
435
435
|
let r = this.extension.register && this.extension.register(e, n.config, n.registerState);
|
|
436
436
|
return this.state = function(e) {
|
|
437
|
-
return Object.assign(e, { id:
|
|
437
|
+
return Object.assign(e, { id: G });
|
|
438
438
|
}(n), () => {
|
|
439
439
|
let e = this.state;
|
|
440
|
-
e.id !==
|
|
441
|
-
return Object.assign(e, { id:
|
|
440
|
+
e.id !== K && z(309, String(n.id), String(K)), this.state = function(e) {
|
|
441
|
+
return Object.assign(e, { id: W });
|
|
442
442
|
}(e), r && r();
|
|
443
443
|
};
|
|
444
444
|
}
|
|
445
445
|
afterRegistration(e) {
|
|
446
446
|
let t = this.state, n;
|
|
447
|
-
return t.id !==
|
|
448
|
-
return Object.assign(e, { id:
|
|
447
|
+
return t.id !== G && z(310, String(t.id), String(G)), this.extension.afterRegistration && (n = this.extension.afterRegistration(e, t.config, t.registerState)), this.state = function(e) {
|
|
448
|
+
return Object.assign(e, { id: K });
|
|
449
449
|
}(t), n;
|
|
450
450
|
}
|
|
451
451
|
getSignal() {
|
|
452
|
-
return this._signal === void 0 &&
|
|
452
|
+
return this._signal === void 0 && z(311), this._signal;
|
|
453
453
|
}
|
|
454
454
|
getInitResult() {
|
|
455
|
-
this.extension.init === void 0 &&
|
|
455
|
+
this.extension.init === void 0 && z(312, this.extension.name);
|
|
456
456
|
let e = this.state;
|
|
457
457
|
return function(e) {
|
|
458
|
-
return e.id >=
|
|
459
|
-
}(e) ||
|
|
458
|
+
return e.id >= U;
|
|
459
|
+
}(e) || z(313, String(e.id), String(U)), e.initResult;
|
|
460
460
|
}
|
|
461
461
|
getInitPeer(e) {
|
|
462
462
|
let t = this.builder.extensionNameMap.get(e);
|
|
@@ -465,8 +465,8 @@ var Re = /* @__PURE__ */ new Set(), ze = class {
|
|
|
465
465
|
getExtensionInitDependency() {
|
|
466
466
|
let e = this.state;
|
|
467
467
|
return function(e) {
|
|
468
|
-
return e.id >=
|
|
469
|
-
}(e) ||
|
|
468
|
+
return e.id >= H;
|
|
469
|
+
}(e) || z(314, String(e.id), String(H)), { config: e.config };
|
|
470
470
|
}
|
|
471
471
|
getPeer(e) {
|
|
472
472
|
let t = this.builder.extensionNameMap.get(e);
|
|
@@ -474,20 +474,20 @@ var Re = /* @__PURE__ */ new Set(), ze = class {
|
|
|
474
474
|
}
|
|
475
475
|
getInitDependency(e) {
|
|
476
476
|
let t = this.builder.getExtensionRep(e);
|
|
477
|
-
return t === void 0 &&
|
|
477
|
+
return t === void 0 && z(315, this.extension.name, e.name), t.getExtensionInitDependency();
|
|
478
478
|
}
|
|
479
479
|
getDependency(e) {
|
|
480
480
|
let t = this.builder.getExtensionRep(e);
|
|
481
|
-
return t === void 0 &&
|
|
481
|
+
return t === void 0 && z(315, this.extension.name, e.name), t.getExtensionDependency();
|
|
482
482
|
}
|
|
483
483
|
getState() {
|
|
484
484
|
let e = this.state;
|
|
485
485
|
return function(e) {
|
|
486
|
-
return e.id >=
|
|
487
|
-
}(e) ||
|
|
486
|
+
return e.id >= K;
|
|
487
|
+
}(e) || z(316, String(e.id), String(K)), e;
|
|
488
488
|
}
|
|
489
489
|
getDirectDependentNames() {
|
|
490
|
-
return this.builder.incomingEdges.get(this.extension.name) ||
|
|
490
|
+
return this.builder.incomingEdges.get(this.extension.name) || Ue;
|
|
491
491
|
}
|
|
492
492
|
getPeerNameSet() {
|
|
493
493
|
let e = this._peerNameSet;
|
|
@@ -497,8 +497,8 @@ var Re = /* @__PURE__ */ new Set(), ze = class {
|
|
|
497
497
|
if (!this._dependency) {
|
|
498
498
|
let e = this.state;
|
|
499
499
|
(function(e) {
|
|
500
|
-
return e.id >=
|
|
501
|
-
})(e) ||
|
|
500
|
+
return e.id >= W;
|
|
501
|
+
})(e) || z(317, this.extension.name), this._dependency = {
|
|
502
502
|
config: e.config,
|
|
503
503
|
init: e.initResult,
|
|
504
504
|
output: e.output
|
|
@@ -506,17 +506,17 @@ var Re = /* @__PURE__ */ new Set(), ze = class {
|
|
|
506
506
|
}
|
|
507
507
|
return this._dependency;
|
|
508
508
|
}
|
|
509
|
-
},
|
|
510
|
-
function
|
|
511
|
-
let e =
|
|
512
|
-
e.isEmpty() && e.append(
|
|
509
|
+
}, Ge = { tag: a };
|
|
510
|
+
function Ke() {
|
|
511
|
+
let e = d();
|
|
512
|
+
e.isEmpty() && e.append(u());
|
|
513
513
|
}
|
|
514
|
-
var
|
|
515
|
-
config:
|
|
516
|
-
setOptions:
|
|
517
|
-
updateOptions:
|
|
514
|
+
var qe = e({
|
|
515
|
+
config: h({
|
|
516
|
+
setOptions: Ge,
|
|
517
|
+
updateOptions: Ge
|
|
518
518
|
}),
|
|
519
|
-
init: ({ $initialEditorState: e =
|
|
519
|
+
init: ({ $initialEditorState: e = Ke }) => ({
|
|
520
520
|
$initialEditorState: e,
|
|
521
521
|
initialized: !1
|
|
522
522
|
}),
|
|
@@ -525,7 +525,7 @@ var He = l({
|
|
|
525
525
|
if (!i.initialized) {
|
|
526
526
|
i.initialized = !0;
|
|
527
527
|
let { $initialEditorState: r } = i;
|
|
528
|
-
if (
|
|
528
|
+
if (ie(r)) e.setEditorState(r, n);
|
|
529
529
|
else if (typeof r == "function") e.update(() => {
|
|
530
530
|
r(e);
|
|
531
531
|
}, t);
|
|
@@ -538,21 +538,21 @@ var He = l({
|
|
|
538
538
|
},
|
|
539
539
|
name: "@lexical/extension/InitialState",
|
|
540
540
|
nodes: [
|
|
541
|
-
|
|
542
|
-
|
|
541
|
+
re,
|
|
542
|
+
ye,
|
|
543
543
|
i,
|
|
544
|
-
|
|
545
|
-
|
|
544
|
+
o,
|
|
545
|
+
we
|
|
546
546
|
]
|
|
547
|
-
}),
|
|
548
|
-
function
|
|
549
|
-
function
|
|
547
|
+
}), Je = Symbol.for("@lexical/extension/LexicalBuilder");
|
|
548
|
+
function Ye() {}
|
|
549
|
+
function Xe(e) {
|
|
550
550
|
throw e;
|
|
551
551
|
}
|
|
552
|
-
function
|
|
552
|
+
function J(e) {
|
|
553
553
|
return Array.isArray(e) ? e : [e];
|
|
554
554
|
}
|
|
555
|
-
var
|
|
555
|
+
var Y = "0.42.0+prod.esm", X = class e {
|
|
556
556
|
roots;
|
|
557
557
|
extensionNameMap;
|
|
558
558
|
outgoingConfigEdges;
|
|
@@ -561,53 +561,53 @@ var Z = "0.41.0+prod.esm", Ke = class e {
|
|
|
561
561
|
_sortedExtensionReps;
|
|
562
562
|
PACKAGE_VERSION;
|
|
563
563
|
constructor(e) {
|
|
564
|
-
this.outgoingConfigEdges = /* @__PURE__ */ new Map(), this.incomingEdges = /* @__PURE__ */ new Map(), this.extensionNameMap = /* @__PURE__ */ new Map(), this.conflicts = /* @__PURE__ */ new Map(), this.PACKAGE_VERSION =
|
|
564
|
+
this.outgoingConfigEdges = /* @__PURE__ */ new Map(), this.incomingEdges = /* @__PURE__ */ new Map(), this.extensionNameMap = /* @__PURE__ */ new Map(), this.conflicts = /* @__PURE__ */ new Map(), this.PACKAGE_VERSION = Y, this.roots = e;
|
|
565
565
|
for (let t of e) this.addExtension(t);
|
|
566
566
|
}
|
|
567
567
|
static fromExtensions(t) {
|
|
568
|
-
let n = [
|
|
569
|
-
for (let e of t) n.push(
|
|
568
|
+
let n = [J(qe)];
|
|
569
|
+
for (let e of t) n.push(J(e));
|
|
570
570
|
return new e(n);
|
|
571
571
|
}
|
|
572
572
|
static maybeFromEditor(t) {
|
|
573
|
-
let n = t[
|
|
574
|
-
return n && (n.PACKAGE_VERSION !==
|
|
573
|
+
let n = t[Je];
|
|
574
|
+
return n && (n.PACKAGE_VERSION !== Y && z(292, n.PACKAGE_VERSION, Y), n instanceof e || z(293)), n;
|
|
575
575
|
}
|
|
576
576
|
static fromEditor(t) {
|
|
577
577
|
let n = e.maybeFromEditor(t);
|
|
578
|
-
return n === void 0 &&
|
|
578
|
+
return n === void 0 && z(294), n;
|
|
579
579
|
}
|
|
580
580
|
constructEditor() {
|
|
581
|
-
let { $initialEditorState: e, onError: t, ...n } = this.buildCreateEditorArgs(), r = Object.assign(
|
|
581
|
+
let { $initialEditorState: e, onError: t, ...n } = this.buildCreateEditorArgs(), r = Object.assign(s({
|
|
582
582
|
...n,
|
|
583
583
|
...t ? { onError: (e) => {
|
|
584
584
|
t(e, r);
|
|
585
585
|
} } : {}
|
|
586
|
-
}), { [
|
|
586
|
+
}), { [Je]: this });
|
|
587
587
|
for (let e of this.sortedExtensionReps()) e.build(r);
|
|
588
588
|
return r;
|
|
589
589
|
}
|
|
590
590
|
buildEditor() {
|
|
591
|
-
let e =
|
|
591
|
+
let e = Ye;
|
|
592
592
|
function t() {
|
|
593
593
|
try {
|
|
594
594
|
e();
|
|
595
595
|
} finally {
|
|
596
|
-
e =
|
|
596
|
+
e = Ye;
|
|
597
597
|
}
|
|
598
598
|
}
|
|
599
599
|
let n = Object.assign(this.constructEditor(), {
|
|
600
600
|
dispose: t,
|
|
601
601
|
[Symbol.dispose]: t
|
|
602
602
|
});
|
|
603
|
-
return e =
|
|
603
|
+
return e = r(this.registerEditor(n), () => n.setRootElement(null)), n;
|
|
604
604
|
}
|
|
605
605
|
hasExtensionByName(e) {
|
|
606
606
|
return this.extensionNameMap.has(e);
|
|
607
607
|
}
|
|
608
608
|
getExtensionRep(e) {
|
|
609
609
|
let t = this.extensionNameMap.get(e.name);
|
|
610
|
-
if (t) return t.extension !== e &&
|
|
610
|
+
if (t) return t.extension !== e && z(295, e.name), t;
|
|
611
611
|
}
|
|
612
612
|
addEdge(e, t, n) {
|
|
613
613
|
let r = this.outgoingConfigEdges.get(e);
|
|
@@ -616,17 +616,17 @@ var Z = "0.41.0+prod.esm", Ke = class e {
|
|
|
616
616
|
i ? i.add(e) : this.incomingEdges.set(t, new Set([e]));
|
|
617
617
|
}
|
|
618
618
|
addExtension(e) {
|
|
619
|
-
this._sortedExtensionReps !== void 0 &&
|
|
620
|
-
let [t] =
|
|
621
|
-
typeof t.name != "string" &&
|
|
619
|
+
this._sortedExtensionReps !== void 0 && z(296);
|
|
620
|
+
let [t] = J(e);
|
|
621
|
+
typeof t.name != "string" && z(297, typeof t.name);
|
|
622
622
|
let n = this.extensionNameMap.get(t.name);
|
|
623
|
-
if (n !== void 0 && n.extension !== t &&
|
|
624
|
-
n = new
|
|
623
|
+
if (n !== void 0 && n.extension !== t && z(298, t.name), !n) {
|
|
624
|
+
n = new We(this, t), this.extensionNameMap.set(t.name, n);
|
|
625
625
|
let e = this.conflicts.get(t.name);
|
|
626
|
-
typeof e == "string" &&
|
|
627
|
-
for (let e of t.conflictsWith || []) this.extensionNameMap.has(e) &&
|
|
626
|
+
typeof e == "string" && z(299, t.name, e);
|
|
627
|
+
for (let e of t.conflictsWith || []) this.extensionNameMap.has(e) && z(299, t.name, e), this.conflicts.set(e, t.name);
|
|
628
628
|
for (let e of t.dependencies || []) {
|
|
629
|
-
let n =
|
|
629
|
+
let n = J(e);
|
|
630
630
|
this.addEdge(t.name, n[0].name, n.slice(1)), this.addExtension(n);
|
|
631
631
|
}
|
|
632
632
|
for (let [e, n] of t.peerDependencies || []) this.addEdge(t.name, e, n ? [n] : []);
|
|
@@ -636,49 +636,49 @@ var Z = "0.41.0+prod.esm", Ke = class e {
|
|
|
636
636
|
if (this._sortedExtensionReps) return this._sortedExtensionReps;
|
|
637
637
|
let e = [], t = (n, r) => {
|
|
638
638
|
let i = n.state;
|
|
639
|
-
if (
|
|
639
|
+
if (Ve(i)) return;
|
|
640
640
|
let a = n.extension.name;
|
|
641
641
|
var o;
|
|
642
|
-
|
|
642
|
+
q(i) || z(300, a, r || "[unknown]"), q(o = i) || z(304, String(o.id), String(B)), i = Object.assign(o, { id: V }), n.state = i;
|
|
643
643
|
let s = this.outgoingConfigEdges.get(a);
|
|
644
644
|
if (s) for (let e of s.keys()) {
|
|
645
645
|
let n = this.extensionNameMap.get(e);
|
|
646
646
|
n && t(n, a);
|
|
647
647
|
}
|
|
648
|
-
i =
|
|
648
|
+
i = He(i), n.state = i, e.push(n);
|
|
649
649
|
};
|
|
650
|
-
for (let e of this.extensionNameMap.values())
|
|
650
|
+
for (let e of this.extensionNameMap.values()) q(e.state) && t(e);
|
|
651
651
|
for (let t of e) for (let [e, n] of this.outgoingConfigEdges.get(t.extension.name) || []) if (n.length > 0) {
|
|
652
652
|
let t = this.extensionNameMap.get(e);
|
|
653
653
|
if (t) for (let e of n) t.configs.add(e);
|
|
654
654
|
}
|
|
655
655
|
for (let [e, ...t] of this.roots) if (t.length > 0) {
|
|
656
656
|
let n = this.extensionNameMap.get(e.name);
|
|
657
|
-
n === void 0 &&
|
|
657
|
+
n === void 0 && z(301, e.name);
|
|
658
658
|
for (let e of t) n.configs.add(e);
|
|
659
659
|
}
|
|
660
660
|
return this._sortedExtensionReps = e, this._sortedExtensionReps;
|
|
661
661
|
}
|
|
662
662
|
registerEditor(e) {
|
|
663
|
-
let t = this.sortedExtensionReps(), n = new AbortController(),
|
|
663
|
+
let t = this.sortedExtensionReps(), n = new AbortController(), i = [() => n.abort()], a = n.signal;
|
|
664
664
|
for (let n of t) {
|
|
665
|
-
let t = n.register(e,
|
|
666
|
-
t &&
|
|
665
|
+
let t = n.register(e, a);
|
|
666
|
+
t && i.push(t);
|
|
667
667
|
}
|
|
668
668
|
for (let n of t) {
|
|
669
669
|
let t = n.afterRegistration(e);
|
|
670
|
-
t &&
|
|
670
|
+
t && i.push(t);
|
|
671
671
|
}
|
|
672
|
-
return
|
|
672
|
+
return r(...i);
|
|
673
673
|
}
|
|
674
674
|
buildCreateEditorArgs() {
|
|
675
675
|
let e = {}, t = /* @__PURE__ */ new Set(), n = /* @__PURE__ */ new Map(), r = /* @__PURE__ */ new Map(), i = {}, a = {}, o = this.sortedExtensionReps();
|
|
676
676
|
for (let s of o) {
|
|
677
677
|
let { extension: o } = s;
|
|
678
|
-
if (o.onError !== void 0 && (e.onError = o.onError), o.disableEvents !== void 0 && (e.disableEvents = o.disableEvents), o.parentEditor !== void 0 && (e.parentEditor = o.parentEditor), o.editable !== void 0 && (e.editable = o.editable), o.namespace !== void 0 && (e.namespace = o.namespace), o.$initialEditorState !== void 0 && (e.$initialEditorState = o.$initialEditorState), o.nodes) for (let e of
|
|
678
|
+
if (o.onError !== void 0 && (e.onError = o.onError), o.disableEvents !== void 0 && (e.disableEvents = o.disableEvents), o.parentEditor !== void 0 && (e.parentEditor = o.parentEditor), o.editable !== void 0 && (e.editable = o.editable), o.namespace !== void 0 && (e.namespace = o.namespace), o.$initialEditorState !== void 0 && (e.$initialEditorState = o.$initialEditorState), o.nodes) for (let e of Fe(o)) {
|
|
679
679
|
if (typeof e != "function") {
|
|
680
680
|
let t = n.get(e.replace);
|
|
681
|
-
t &&
|
|
681
|
+
t && z(302, o.name, e.replace.name, t.extension.name), n.set(e.replace, s);
|
|
682
682
|
}
|
|
683
683
|
t.add(e);
|
|
684
684
|
}
|
|
@@ -686,44 +686,42 @@ var Z = "0.41.0+prod.esm", Ke = class e {
|
|
|
686
686
|
if (o.html.export) for (let [e, t] of o.html.export.entries()) r.set(e, t);
|
|
687
687
|
o.html.import && Object.assign(i, o.html.import);
|
|
688
688
|
}
|
|
689
|
-
o.theme &&
|
|
689
|
+
o.theme && ze(a, o.theme);
|
|
690
690
|
}
|
|
691
691
|
Object.keys(a).length > 0 && (e.theme = a), t.size && (e.nodes = [...t]);
|
|
692
692
|
let s = Object.keys(i).length > 0, c = r.size > 0;
|
|
693
693
|
(s || c) && (e.html = {}, s && (e.html.import = i), c && (e.html.export = r));
|
|
694
694
|
for (let t of o) t.init(e);
|
|
695
|
-
return e.onError ||=
|
|
695
|
+
return e.onError ||= Xe, e;
|
|
696
696
|
}
|
|
697
697
|
};
|
|
698
|
-
function
|
|
699
|
-
let n =
|
|
698
|
+
function Ze(e, t) {
|
|
699
|
+
let n = X.fromEditor(e).extensionNameMap.get(t);
|
|
700
700
|
return n ? n.getExtensionDependency() : void 0;
|
|
701
701
|
}
|
|
702
|
-
var
|
|
702
|
+
var Qe = /* @__PURE__ */ new Set(), $e = e({
|
|
703
703
|
build(e, t, n) {
|
|
704
|
-
let r = n.getDependency(
|
|
705
|
-
let e = a.peek(), { watchedNodeKeys: t } = i.value, n,
|
|
704
|
+
let r = n.getDependency(R).output, i = O({ watchedNodeKeys: /* @__PURE__ */ new Map() }), a = Re(() => {}, () => F(() => {
|
|
705
|
+
let e = a.peek(), { watchedNodeKeys: t } = i.value, n, o = !1;
|
|
706
706
|
r.value.read(() => {
|
|
707
|
-
if (
|
|
707
|
+
if (g()) for (let [r, i] of t.entries()) {
|
|
708
708
|
if (i.size === 0) {
|
|
709
709
|
t.delete(r);
|
|
710
710
|
continue;
|
|
711
711
|
}
|
|
712
|
-
let a =
|
|
713
|
-
|
|
712
|
+
let a = ge(r), s = a && a.isSelected() || !1;
|
|
713
|
+
o ||= s !== (!!e && e.has(r)), s && (n ||= /* @__PURE__ */ new Set(), n.add(r));
|
|
714
714
|
}
|
|
715
|
-
}), !
|
|
715
|
+
}), !o && n && e && n.size === e.size || (a.value = n);
|
|
716
716
|
}));
|
|
717
717
|
return { watchNodeKey: function(e) {
|
|
718
|
-
let t =
|
|
718
|
+
let t = Ae(() => (a.value || Qe).has(e)), { watchedNodeKeys: n } = i.peek(), r = n.get(e), o = r !== void 0;
|
|
719
719
|
return r ||= /* @__PURE__ */ new Set(), r.add(t), o || (n.set(e, r), i.value = { watchedNodeKeys: n }), t;
|
|
720
720
|
} };
|
|
721
721
|
},
|
|
722
|
-
dependencies: [
|
|
722
|
+
dependencies: [R],
|
|
723
723
|
name: "@lexical/extension/NodeSelection"
|
|
724
|
-
})
|
|
725
|
-
ce("INSERT_HORIZONTAL_RULE_COMMAND");
|
|
726
|
-
var Q = class e extends u {
|
|
724
|
+
}), et = pe("INSERT_HORIZONTAL_RULE_COMMAND"), Z = class e extends _ {
|
|
727
725
|
static getType() {
|
|
728
726
|
return "horizontalrule";
|
|
729
727
|
}
|
|
@@ -731,11 +729,11 @@ var Q = class e extends u {
|
|
|
731
729
|
return new e(t.__key);
|
|
732
730
|
}
|
|
733
731
|
static importJSON(e) {
|
|
734
|
-
return
|
|
732
|
+
return Q().updateFromJSON(e);
|
|
735
733
|
}
|
|
736
734
|
static importDOM() {
|
|
737
735
|
return { hr: () => ({
|
|
738
|
-
conversion:
|
|
736
|
+
conversion: tt,
|
|
739
737
|
priority: 0
|
|
740
738
|
}) };
|
|
741
739
|
}
|
|
@@ -744,7 +742,7 @@ var Q = class e extends u {
|
|
|
744
742
|
}
|
|
745
743
|
createDOM(e) {
|
|
746
744
|
let t = document.createElement("hr");
|
|
747
|
-
return
|
|
745
|
+
return f(t, e.theme.hr), t;
|
|
748
746
|
}
|
|
749
747
|
getTextContent() {
|
|
750
748
|
return "\n";
|
|
@@ -756,86 +754,120 @@ var Q = class e extends u {
|
|
|
756
754
|
return !1;
|
|
757
755
|
}
|
|
758
756
|
};
|
|
759
|
-
function
|
|
760
|
-
return { node:
|
|
757
|
+
function tt() {
|
|
758
|
+
return { node: Q() };
|
|
761
759
|
}
|
|
762
|
-
function
|
|
763
|
-
return
|
|
760
|
+
function Q() {
|
|
761
|
+
return c(Z);
|
|
764
762
|
}
|
|
765
|
-
function
|
|
766
|
-
return e instanceof
|
|
763
|
+
function nt(e) {
|
|
764
|
+
return e instanceof Z;
|
|
767
765
|
}
|
|
768
|
-
|
|
769
|
-
dependencies: [
|
|
766
|
+
e({
|
|
767
|
+
dependencies: [R, $e],
|
|
770
768
|
name: "@lexical/extension/HorizontalRule",
|
|
771
|
-
nodes: () => [
|
|
772
|
-
register(e,
|
|
773
|
-
let { watchNodeKey:
|
|
774
|
-
return
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
769
|
+
nodes: () => [Z],
|
|
770
|
+
register(e, n, i) {
|
|
771
|
+
let { watchNodeKey: a } = i.getDependency($e).output, o = O({ nodeSelections: /* @__PURE__ */ new Map() }), s = e._config.theme.hrSelected ?? "selected";
|
|
772
|
+
return r(e.registerCommand(et, (e) => {
|
|
773
|
+
let t = g();
|
|
774
|
+
return l(t) ? (t.focus.getNode() !== null && Oe(Q()), !0) : !1;
|
|
775
|
+
}, 0), e.registerCommand(ve, (e) => {
|
|
776
|
+
if (le(e.target)) {
|
|
777
|
+
let n = Ce(e.target);
|
|
778
|
+
if (nt(n)) return function(e, n = !1) {
|
|
779
|
+
let r = g(), i = e.isSelected(), a = e.getKey(), o;
|
|
780
|
+
n && fe(r) ? o = r : (o = t(), be(o)), i ? o.delete(a) : o.add(a);
|
|
781
|
+
}(n, e.shiftKey), !0;
|
|
781
782
|
}
|
|
782
783
|
return !1;
|
|
783
|
-
}, 1), e.registerMutationListener(
|
|
784
|
-
|
|
784
|
+
}, 1), e.registerMutationListener(Z, (t, n) => {
|
|
785
|
+
y(() => {
|
|
785
786
|
let n = !1, { nodeSelections: r } = o.peek();
|
|
786
|
-
for (let [
|
|
787
|
+
for (let [i, o] of t.entries()) if (o === "destroyed") r.delete(i), n = !0;
|
|
787
788
|
else {
|
|
788
|
-
let t = r.get(
|
|
789
|
-
t ? t.domNode.value = o : (n = !0, r.set(
|
|
790
|
-
domNode:
|
|
791
|
-
selectedSignal: i
|
|
789
|
+
let t = r.get(i), o = e.getElementByKey(i);
|
|
790
|
+
t ? t.domNode.value = o : (n = !0, r.set(i, {
|
|
791
|
+
domNode: O(o),
|
|
792
|
+
selectedSignal: a(i)
|
|
792
793
|
}));
|
|
793
794
|
}
|
|
794
795
|
n && (o.value = { nodeSelections: r });
|
|
795
796
|
});
|
|
796
|
-
}),
|
|
797
|
+
}), F(() => {
|
|
797
798
|
let e = [];
|
|
798
|
-
for (let { domNode: t, selectedSignal:
|
|
799
|
+
for (let { domNode: t, selectedSignal: n } of o.value.nodeSelections.values()) e.push(F(() => {
|
|
799
800
|
let e = t.value;
|
|
800
|
-
e && (
|
|
801
|
+
e && (n.value ? f(e, s) : de(e, s));
|
|
801
802
|
}));
|
|
802
|
-
return
|
|
803
|
+
return r(...e);
|
|
803
804
|
}));
|
|
804
805
|
}
|
|
806
|
+
}), e({
|
|
807
|
+
build: (e, t) => I({ inheritEditableFromParent: t.inheritEditableFromParent }),
|
|
808
|
+
config: h({
|
|
809
|
+
$getParentEditor: function() {
|
|
810
|
+
let e = oe();
|
|
811
|
+
return X.fromEditor(e), e;
|
|
812
|
+
},
|
|
813
|
+
inheritEditableFromParent: !1
|
|
814
|
+
}),
|
|
815
|
+
init: (e, t, n) => {
|
|
816
|
+
let r = t.$getParentEditor();
|
|
817
|
+
e.parentEditor = r, e.theme = e.theme || r._config.theme;
|
|
818
|
+
},
|
|
819
|
+
name: "@lexical/extension/NestedEditor",
|
|
820
|
+
register: (e, t, n) => F(() => {
|
|
821
|
+
let t = e._parentEditor;
|
|
822
|
+
if (t && n.getOutput().inheritEditableFromParent.value) return e.setEditable(t.isEditable()), t.registerEditableListener(e.setEditable.bind(e));
|
|
823
|
+
})
|
|
824
|
+
}), e({
|
|
825
|
+
build: (e, t, n) => I(t),
|
|
826
|
+
config: h({
|
|
827
|
+
disabled: !1,
|
|
828
|
+
onReposition: void 0
|
|
829
|
+
}),
|
|
830
|
+
name: "@lexical/utils/SelectionAlwaysOnDisplay",
|
|
831
|
+
register: (e, t, n) => {
|
|
832
|
+
let r = n.getOutput();
|
|
833
|
+
return F(() => {
|
|
834
|
+
if (!r.disabled.value) return Te(e, r.onReposition.value);
|
|
835
|
+
});
|
|
836
|
+
}
|
|
805
837
|
});
|
|
806
838
|
function $(e) {
|
|
807
839
|
return e.canBeEmpty();
|
|
808
840
|
}
|
|
809
|
-
function
|
|
810
|
-
return
|
|
811
|
-
let
|
|
812
|
-
if (!
|
|
841
|
+
function rt(e, t, i = $) {
|
|
842
|
+
return r(e.registerCommand(ce, (t) => {
|
|
843
|
+
let r = g();
|
|
844
|
+
if (!l(r)) return !1;
|
|
813
845
|
t.preventDefault();
|
|
814
846
|
let i = function(e) {
|
|
815
|
-
if (e.getNodes().filter((e) =>
|
|
816
|
-
let t = e.anchor, n = e.focus,
|
|
817
|
-
if (
|
|
818
|
-
let e =
|
|
819
|
-
if (t.anchor.set(e, 0, "element"), t.focus.set(e, 0, "element"), t =
|
|
847
|
+
if (e.getNodes().filter((e) => Se(e) && e.canIndent()).length > 0) return !0;
|
|
848
|
+
let t = e.anchor, n = e.focus, r = n.isBefore(t) ? n : t, i = Ee(r.getNode());
|
|
849
|
+
if (i.canIndent()) {
|
|
850
|
+
let e = i.getKey(), t = ne();
|
|
851
|
+
if (t.anchor.set(e, 0, "element"), t.focus.set(e, 0, "element"), t = me(t), t.anchor.is(r)) return !0;
|
|
820
852
|
}
|
|
821
853
|
return !1;
|
|
822
|
-
}(
|
|
854
|
+
}(r) ? t.shiftKey ? te : p : n;
|
|
823
855
|
return e.dispatchCommand(i, void 0);
|
|
824
|
-
}, 0), e.registerCommand(
|
|
856
|
+
}, 0), e.registerCommand(p, () => {
|
|
825
857
|
let e = typeof t == "number" ? t : t ? t.peek() : null;
|
|
826
|
-
if (!g(
|
|
827
|
-
let
|
|
828
|
-
return
|
|
829
|
-
if (
|
|
858
|
+
if (!l(g())) return !1;
|
|
859
|
+
let n = typeof i == "function" ? i : i.peek();
|
|
860
|
+
return De((t) => {
|
|
861
|
+
if (n(t)) {
|
|
830
862
|
let n = t.getIndent() + 1;
|
|
831
863
|
(!e || n < e) && t.setIndent(n);
|
|
832
864
|
}
|
|
833
865
|
});
|
|
834
866
|
}, 4));
|
|
835
867
|
}
|
|
836
|
-
|
|
837
|
-
build: (e, t, n) =>
|
|
838
|
-
config:
|
|
868
|
+
e({
|
|
869
|
+
build: (e, t, n) => I(t),
|
|
870
|
+
config: h({
|
|
839
871
|
$canIndent: $,
|
|
840
872
|
disabled: !1,
|
|
841
873
|
maxIndent: null
|
|
@@ -843,12 +875,12 @@ l({
|
|
|
843
875
|
name: "@lexical/extension/TabIndentation",
|
|
844
876
|
register(e, t, n) {
|
|
845
877
|
let { disabled: r, maxIndent: i, $canIndent: a } = n.getOutput();
|
|
846
|
-
return
|
|
847
|
-
if (!r.value) return
|
|
878
|
+
return F(() => {
|
|
879
|
+
if (!r.value) return rt(e, i, a);
|
|
848
880
|
});
|
|
849
881
|
}
|
|
850
882
|
});
|
|
851
883
|
//#endregion
|
|
852
|
-
export {
|
|
884
|
+
export { F as a, X as i, Ze as n, I as o, O as r, y as t };
|
|
853
885
|
|
|
854
|
-
//# sourceMappingURL=LexicalExtension.prod-
|
|
886
|
+
//# sourceMappingURL=LexicalExtension.prod-COPHoPpX.js.map
|