@uva-glass/component-library 1.63.0 → 1.64.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/Lexical.prod-DSqOWcE1.js +4072 -0
- package/dist/Lexical.prod-DSqOWcE1.js.map +1 -0
- package/dist/{LexicalClipboard.prod-C6LsK5E6.js → LexicalClipboard.prod-DP0us-xV.js} +107 -107
- package/dist/{LexicalClipboard.prod-C6LsK5E6.js.map → LexicalClipboard.prod-DP0us-xV.js.map} +1 -1
- package/dist/LexicalLink.prod-DWrTW8iE.js +208 -0
- package/dist/LexicalLink.prod-DWrTW8iE.js.map +1 -0
- package/dist/LexicalList.prod-Cg8npow-.js +564 -0
- package/dist/LexicalList.prod-Cg8npow-.js.map +1 -0
- package/dist/LexicalTable.prod-DEA4KRzX.js +1221 -0
- package/dist/LexicalTable.prod-DEA4KRzX.js.map +1 -0
- package/dist/{LexicalUtils.prod-BTFNWAMw.js → LexicalUtils.prod-CicP_X7u.js} +44 -35
- package/dist/{LexicalUtils.prod-BTFNWAMw.js.map → LexicalUtils.prod-CicP_X7u.js.map} +1 -1
- package/dist/{TablePlugin-BLzR0g93.js → TablePlugin-BBOjr3TX.js} +56 -58
- package/dist/{TablePlugin-BLzR0g93.js.map → TablePlugin-BBOjr3TX.js.map} +1 -1
- package/dist/assets/AccordionCard.css +1 -0
- package/dist/components/AccordionCard/AccordionCard.d.ts +10 -0
- package/dist/components/AccordionCard/AccordionCard.js +58 -0
- package/dist/components/AccordionCard/AccordionCard.js.map +1 -0
- package/dist/components/AccordionCard/AccordionCard.stories.d.ts +5 -0
- package/dist/components/AccordionCard/AccordionCard.stories.js +33 -0
- package/dist/components/AccordionCard/AccordionCard.stories.js.map +1 -0
- package/dist/components/AccordionCard/index.d.ts +1 -0
- package/dist/components/AccordionCard/index.js +5 -0
- package/dist/components/AccordionCard/index.js.map +1 -0
- package/dist/components/CheckboxTree/CheckboxTree.js +18 -21
- package/dist/components/CheckboxTree/CheckboxTree.js.map +1 -1
- package/dist/components/FormInput/FormInput.js +12 -15
- package/dist/components/FormInput/FormInput.js.map +1 -1
- package/dist/components/InputField/InputField.stories.js +13 -16
- package/dist/components/InputField/InputField.stories.js.map +1 -1
- package/dist/components/MultiSelect/MultiSelect.js +1 -1
- package/dist/components/MultiSelect/MultiSelect.stories.js +1 -1
- package/dist/components/MultiSelect/components/MultiSelectHeader.js +3 -6
- package/dist/components/MultiSelect/components/MultiSelectHeader.js.map +1 -1
- package/dist/components/MultiSelect/index.js +1 -1
- package/dist/components/PeriodSelector/PeriodSelector.js +19 -22
- package/dist/components/PeriodSelector/PeriodSelector.js.map +1 -1
- package/dist/components/ProgrammeCard/ProgrammeCard.stories.js +17 -20
- package/dist/components/ProgrammeCard/ProgrammeCard.stories.js.map +1 -1
- package/dist/components/RteEditor/EditorHeader/EditorHeader.js +4 -7
- package/dist/components/RteEditor/EditorHeader/EditorHeader.js.map +1 -1
- package/dist/components/RteEditor/Plugins/BlockFormatPlugin/BlockFormatPlugin.js +16 -16
- package/dist/components/RteEditor/Plugins/HistoryPlugin/HistoryPlugin.js +26 -28
- package/dist/components/RteEditor/Plugins/HistoryPlugin/HistoryPlugin.js.map +1 -1
- package/dist/components/RteEditor/Plugins/LinkPlugin/AddLinkForm/AddLinkFrom.js +4 -7
- package/dist/components/RteEditor/Plugins/LinkPlugin/AddLinkForm/AddLinkFrom.js.map +1 -1
- package/dist/components/RteEditor/Plugins/LinkPlugin/LinkContextMenu/LinkContextMenu.js +1 -1
- package/dist/components/RteEditor/Plugins/LinkPlugin/LinkPlugin.js +100 -101
- package/dist/components/RteEditor/Plugins/LinkPlugin/LinkPlugin.js.map +1 -1
- package/dist/components/RteEditor/Plugins/LinkPlugin/helpers.js +1 -1
- package/dist/components/RteEditor/Plugins/ListPlugin/ListPlugin.js +35 -35
- package/dist/components/RteEditor/Plugins/ListPlugin/ListPlugin.js.map +1 -1
- package/dist/components/RteEditor/Plugins/PasteHandlerPlugin/PasteHandlerPlugin.js +15 -15
- package/dist/components/RteEditor/Plugins/PasteHandlerPlugin/PasteHandlerPlugin.js.map +1 -1
- package/dist/components/RteEditor/Plugins/TablePlugin/AddTableFrom.js +3 -6
- package/dist/components/RteEditor/Plugins/TablePlugin/AddTableFrom.js.map +1 -1
- package/dist/components/RteEditor/Plugins/TablePlugin/TablePlugin.js +5 -7
- package/dist/components/RteEditor/Plugins/TablePlugin/TablePlugin.js.map +1 -1
- package/dist/components/RteEditor/Plugins/TablePlugin/helpers.js +12 -12
- package/dist/components/RteEditor/Plugins/TablePlugin/index.js +1 -1
- package/dist/components/RteEditor/Plugins/ToolbarPlugin/ToolbarPlugin.js +34 -34
- package/dist/components/RteEditor/Plugins/index.js +1 -1
- package/dist/components/RteEditor/RteEditor.js +354 -354
- package/dist/components/RteEditor/RteEditor.js.map +1 -1
- package/dist/components/RteEditor/helpers.js +27 -27
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +98 -96
- package/dist/components/index.js.map +1 -1
- package/dist/helpers-BuSJOvGF.js +168 -0
- package/dist/{helpers-B-pdj8pq.js.map → helpers-BuSJOvGF.js.map} +1 -1
- package/dist/index-DPQ9bZx5.js +231 -0
- package/dist/index-DPQ9bZx5.js.map +1 -0
- package/dist/index.js +98 -96
- package/dist/index.js.map +1 -1
- package/package.json +8 -6
- package/dist/LexicalTable.prod-DqzrJuYr.js +0 -1221
- package/dist/LexicalTable.prod-DqzrJuYr.js.map +0 -1
- package/dist/helpers-B-pdj8pq.js +0 -168
|
@@ -1,31 +1,31 @@
|
|
|
1
1
|
import { u as m } from "../../../../LexicalComposerContext.prod-Dyvim1tK.js";
|
|
2
2
|
import { useEffect as c } from "react";
|
|
3
|
-
import {
|
|
4
|
-
import { i
|
|
5
|
-
import { _ as
|
|
6
|
-
import {
|
|
7
|
-
const
|
|
8
|
-
const [
|
|
9
|
-
t.preventDefault(),
|
|
10
|
-
const
|
|
11
|
-
if (n != null &&
|
|
12
|
-
const
|
|
13
|
-
|
|
3
|
+
import { Y as f, z as u, M as d } from "../../../../Lexical.prod-DSqOWcE1.js";
|
|
4
|
+
import { i } from "../../../../LexicalUtils.prod-CicP_X7u.js";
|
|
5
|
+
import { _ as p } from "../../../../LexicalClipboard.prod-DP0us-xV.js";
|
|
6
|
+
import { d as D } from "../../../../index-DPQ9bZx5.js";
|
|
7
|
+
const P = () => {
|
|
8
|
+
const [e] = m(), l = (t) => {
|
|
9
|
+
t.preventDefault(), e.update(() => {
|
|
10
|
+
const r = d(), n = i(t, InputEvent) || i(t, KeyboardEvent) ? null : t.clipboardData;
|
|
11
|
+
if (n != null && r !== null) {
|
|
12
|
+
const a = n.getData("text/html"), o = new DataTransfer(), s = new D.MSWordNormalizer();
|
|
13
|
+
o.setData("text/html", a), s.isActive(a) && o.setData("text/html", s.normalize(a)), p(o, r, e);
|
|
14
14
|
}
|
|
15
15
|
});
|
|
16
16
|
};
|
|
17
17
|
return c(() => {
|
|
18
|
-
const t =
|
|
18
|
+
const t = e.registerCommand(
|
|
19
19
|
f,
|
|
20
|
-
(
|
|
20
|
+
(r) => r instanceof ClipboardEvent ? (l(r), !0) : !1,
|
|
21
21
|
u
|
|
22
22
|
);
|
|
23
23
|
return () => {
|
|
24
24
|
t();
|
|
25
25
|
};
|
|
26
|
-
}, [
|
|
26
|
+
}, [e]), null;
|
|
27
27
|
};
|
|
28
28
|
export {
|
|
29
|
-
|
|
29
|
+
P as PasteHandlerPlugin
|
|
30
30
|
};
|
|
31
31
|
//# sourceMappingURL=PasteHandlerPlugin.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PasteHandlerPlugin.js","sources":["../../../../../src/components/RteEditor/Plugins/PasteHandlerPlugin/PasteHandlerPlugin.tsx"],"sourcesContent":["import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext';\nimport { useEffect } from 'react';\nimport { $getSelection, COMMAND_PRIORITY_CRITICAL, type CommandPayloadType, PASTE_COMMAND } from 'lexical';\nimport { objectKlassEquals } from '@lexical/utils';\nimport { $insertDataTransferForRichText } from '@lexical/clipboard';\nimport { MSWordNormalizer } from '@staartwind.nl/lexical-paste-from-word';\n\nexport const PasteHandlerPlugin = () => {\n const [editor] = useLexicalComposerContext();\n\n const handlePaste = (event: CommandPayloadType<typeof PASTE_COMMAND>) => {\n event.preventDefault();\n editor.update(() => {\n const selection = $getSelection();\n const clipboardData =\n objectKlassEquals(event, InputEvent) || objectKlassEquals(event, KeyboardEvent)\n ? null\n : (event as ClipboardEvent).clipboardData;\n if (clipboardData != null && selection !== null) {\n const html = clipboardData.getData('text/html');\n const newData = new DataTransfer();\n const wordNormalizer = new MSWordNormalizer();\n newData.setData('text/html', html);\n if (wordNormalizer.isActive(html)) {\n newData.setData('text/html', wordNormalizer.normalize(html));\n }\n $insertDataTransferForRichText(newData, selection, editor);\n }\n });\n };\n\n useEffect(() => {\n const removePasteListener = editor.registerCommand(\n PASTE_COMMAND,\n (event) => {\n if (event instanceof ClipboardEvent) {\n handlePaste(event);\n return true;\n }\n return false;\n },\n COMMAND_PRIORITY_CRITICAL\n );\n\n return () => {\n removePasteListener();\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [editor]);\n\n return null;\n};\n"],"names":["PasteHandlerPlugin","editor","useLexicalComposerContext","handlePaste","event","selection","$getSelection","clipboardData","objectKlassEquals","html","newData","wordNormalizer","MSWordNormalizer","$insertDataTransferForRichText","useEffect","removePasteListener","PASTE_COMMAND","COMMAND_PRIORITY_CRITICAL"],"mappings":";;;;;;AAOO,MAAMA,IAAqB,MAAM;AAChC,QAAA,CAACC,CAAM,IAAIC,KAEXC,IAAc,CAACC,MAAoD;AACvE,IAAAA,EAAM,eAAe,GACrBH,EAAO,OAAO,MAAM;AAClB,YAAMI,IAAYC,KACZC,IACJC,EAAkBJ,GAAO,UAAU,KAAKI,EAAkBJ,GAAO,aAAa,IAC1E,OACCA,EAAyB;AAC5B,UAAAG,KAAiB,QAAQF,MAAc,MAAM;AACzC,cAAAI,IAAOF,EAAc,QAAQ,WAAW,GACxCG,IAAU,IAAI,gBACdC,IAAiB,IAAIC;AACnB,QAAAF,EAAA,QAAQ,aAAaD,CAAI,GAC7BE,EAAe,SAASF,CAAI,KAC9BC,EAAQ,QAAQ,aAAaC,EAAe,UAAUF,CAAI,CAAC,GAE9BI,EAAAH,GAASL,GAAWJ,CAAM;AAAA,MAC3D;AAAA,IAAA,CACD;AAAA,EAAA;AAGH,SAAAa,EAAU,MAAM;AACd,UAAMC,IAAsBd,EAAO;AAAA,MACjCe;
|
|
1
|
+
{"version":3,"file":"PasteHandlerPlugin.js","sources":["../../../../../src/components/RteEditor/Plugins/PasteHandlerPlugin/PasteHandlerPlugin.tsx"],"sourcesContent":["import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext';\nimport { useEffect } from 'react';\nimport { $getSelection, COMMAND_PRIORITY_CRITICAL, type CommandPayloadType, PASTE_COMMAND } from 'lexical';\nimport { objectKlassEquals } from '@lexical/utils';\nimport { $insertDataTransferForRichText } from '@lexical/clipboard';\nimport { MSWordNormalizer } from '@staartwind.nl/lexical-paste-from-word';\n\nexport const PasteHandlerPlugin = () => {\n const [editor] = useLexicalComposerContext();\n\n const handlePaste = (event: CommandPayloadType<typeof PASTE_COMMAND>) => {\n event.preventDefault();\n editor.update(() => {\n const selection = $getSelection();\n const clipboardData =\n objectKlassEquals(event, InputEvent) || objectKlassEquals(event, KeyboardEvent)\n ? null\n : (event as ClipboardEvent).clipboardData;\n if (clipboardData != null && selection !== null) {\n const html = clipboardData.getData('text/html');\n const newData = new DataTransfer();\n const wordNormalizer = new MSWordNormalizer();\n newData.setData('text/html', html);\n if (wordNormalizer.isActive(html)) {\n newData.setData('text/html', wordNormalizer.normalize(html));\n }\n $insertDataTransferForRichText(newData, selection, editor);\n }\n });\n };\n\n useEffect(() => {\n const removePasteListener = editor.registerCommand(\n PASTE_COMMAND,\n (event) => {\n if (event instanceof ClipboardEvent) {\n handlePaste(event);\n return true;\n }\n return false;\n },\n COMMAND_PRIORITY_CRITICAL\n );\n\n return () => {\n removePasteListener();\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [editor]);\n\n return null;\n};\n"],"names":["PasteHandlerPlugin","editor","useLexicalComposerContext","handlePaste","event","selection","$getSelection","clipboardData","objectKlassEquals","html","newData","wordNormalizer","MSWordNormalizer","$insertDataTransferForRichText","useEffect","removePasteListener","PASTE_COMMAND","COMMAND_PRIORITY_CRITICAL"],"mappings":";;;;;;AAOO,MAAMA,IAAqB,MAAM;AAChC,QAAA,CAACC,CAAM,IAAIC,KAEXC,IAAc,CAACC,MAAoD;AACvE,IAAAA,EAAM,eAAe,GACrBH,EAAO,OAAO,MAAM;AAClB,YAAMI,IAAYC,KACZC,IACJC,EAAkBJ,GAAO,UAAU,KAAKI,EAAkBJ,GAAO,aAAa,IAC1E,OACCA,EAAyB;AAC5B,UAAAG,KAAiB,QAAQF,MAAc,MAAM;AACzC,cAAAI,IAAOF,EAAc,QAAQ,WAAW,GACxCG,IAAU,IAAI,gBACdC,IAAiB,IAAIC,EAAAA;AACnB,QAAAF,EAAA,QAAQ,aAAaD,CAAI,GAC7BE,EAAe,SAASF,CAAI,KAC9BC,EAAQ,QAAQ,aAAaC,EAAe,UAAUF,CAAI,CAAC,GAE9BI,EAAAH,GAASL,GAAWJ,CAAM;AAAA,MAC3D;AAAA,IAAA,CACD;AAAA,EAAA;AAGH,SAAAa,EAAU,MAAM;AACd,UAAMC,IAAsBd,EAAO;AAAA,MACjCe;AAAAA,MACA,CAACZ,MACKA,aAAiB,kBACnBD,EAAYC,CAAK,GACV,MAEF;AAAA,MAETa;AAAAA,IAAA;AAGF,WAAO,MAAM;AACS,MAAAF;IAAA;AAAA,EACtB,GAEC,CAACd,CAAM,CAAC,GAEJ;AACT;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
|
-
import { b as
|
|
3
|
+
import { b as z } from "../../../../TablePlugin-BBOjr3TX.js";
|
|
4
4
|
import "../../../Buttons/Button.js";
|
|
5
5
|
import "../../../Buttons/LinkButton.js";
|
|
6
6
|
import "@react-aria/button";
|
|
@@ -15,20 +15,17 @@ import "../../../IconButton/IconButton.js";
|
|
|
15
15
|
import "../../../Input/Input.js";
|
|
16
16
|
import "../../../InputField/InputField.js";
|
|
17
17
|
import "react-router-dom";
|
|
18
|
-
import "lexical";
|
|
19
|
-
import "@lexical/list";
|
|
20
|
-
import "@lexical/link";
|
|
21
18
|
import "../../helpers.js";
|
|
22
19
|
import "../../hooks/useTranslation.js";
|
|
23
20
|
import "../LinkPlugin/LinkContextMenu/LinkContextMenu.js";
|
|
24
21
|
import "../../hooks/components/Flyout.js";
|
|
25
22
|
import "../../Providers/LanguageProvider.js";
|
|
26
|
-
import "
|
|
23
|
+
import "../../../../index-DPQ9bZx5.js";
|
|
27
24
|
import "../../../SelectListbox/SelectListbox.js";
|
|
28
25
|
import "../../../SelectListbox/SelectProvider.js";
|
|
29
26
|
import "../../../Sortable/components/SortableItem.js";
|
|
30
27
|
import "../../../../SortableProvider-BUsvniX7.js";
|
|
31
28
|
export {
|
|
32
|
-
|
|
29
|
+
z as AddTableForm
|
|
33
30
|
};
|
|
34
31
|
//# sourceMappingURL=AddTableFrom.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AddTableFrom.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AddTableFrom.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "../../../../LexicalComposerContext.prod-Dyvim1tK.js";
|
|
3
3
|
import "../../../../clsx-OuTLNxxd.js";
|
|
4
|
-
import "../../../../LexicalTable.prod-
|
|
5
|
-
import "
|
|
4
|
+
import "../../../../LexicalTable.prod-DEA4KRzX.js";
|
|
5
|
+
import "../../../../Lexical.prod-DSqOWcE1.js";
|
|
6
6
|
import "react";
|
|
7
|
-
import { T as
|
|
7
|
+
import { T as E } from "../../../../TablePlugin-BBOjr3TX.js";
|
|
8
8
|
import "./helpers.js";
|
|
9
9
|
import "../../hooks/useFlyout.js";
|
|
10
10
|
import "../../../Icon/Icon.js";
|
|
@@ -20,18 +20,16 @@ import "../../../IconButton/IconButton.js";
|
|
|
20
20
|
import "../../../Input/Input.js";
|
|
21
21
|
import "../../../InputField/InputField.js";
|
|
22
22
|
import "react-router-dom";
|
|
23
|
-
import "@lexical/list";
|
|
24
|
-
import "@lexical/link";
|
|
25
23
|
import "../../../../RteEditor.module-DcvGRx3a.js";
|
|
26
24
|
import "../../hooks/useTranslation.js";
|
|
27
25
|
import "../LinkPlugin/LinkContextMenu/LinkContextMenu.js";
|
|
28
26
|
import "../../Providers/LanguageProvider.js";
|
|
29
|
-
import "
|
|
27
|
+
import "../../../../index-DPQ9bZx5.js";
|
|
30
28
|
import "../../../SelectListbox/SelectListbox.js";
|
|
31
29
|
import "../../../SelectListbox/SelectProvider.js";
|
|
32
30
|
import "../../../Sortable/components/SortableItem.js";
|
|
33
31
|
import "../../../../SortableProvider-BUsvniX7.js";
|
|
34
32
|
export {
|
|
35
|
-
|
|
33
|
+
E as TablePlugin
|
|
36
34
|
};
|
|
37
35
|
//# sourceMappingURL=TablePlugin.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TablePlugin.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"TablePlugin.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { d as S, a as h, n as d, f as C, p as w, o as m, m as
|
|
2
|
-
import {
|
|
1
|
+
import { d as S, a as h, n as d, f as C, p as w, o as m, m as D, C as p, T as E } from "../../../../LexicalTable.prod-DEA4KRzX.js";
|
|
2
|
+
import { D as u } from "../../../../Lexical.prod-DSqOWcE1.js";
|
|
3
3
|
const b = 100, O = (e, n) => {
|
|
4
4
|
const t = S(0, 0, !1);
|
|
5
5
|
for (let o = 0; o < e; o++) {
|
|
@@ -11,15 +11,15 @@ const b = 100, O = (e, n) => {
|
|
|
11
11
|
t.append(r);
|
|
12
12
|
}
|
|
13
13
|
return t;
|
|
14
|
-
},
|
|
14
|
+
}, z = (e) => {
|
|
15
15
|
const n = C(e), t = n.getNextSibling() || n.getPreviousSibling(), o = n.getParentOrThrow();
|
|
16
16
|
if (o.getChildrenSize() > 1 ? n.remove() : o.remove(), t !== null) {
|
|
17
17
|
const r = t.getFirstDescendant();
|
|
18
18
|
r && r.select();
|
|
19
19
|
}
|
|
20
|
-
},
|
|
20
|
+
}, I = (e) => {
|
|
21
21
|
w(e).remove();
|
|
22
|
-
},
|
|
22
|
+
}, F = (e, n) => {
|
|
23
23
|
const t = h(), o = C(e), r = o.getChildrenSize();
|
|
24
24
|
for (let s = 0; s < r; s++) {
|
|
25
25
|
const c = d(0);
|
|
@@ -28,11 +28,11 @@ const b = 100, O = (e, n) => {
|
|
|
28
28
|
n === "insertRowAbove" ? o.insertBefore(t) : o.insertAfter(t);
|
|
29
29
|
const l = t.getFirstDescendant();
|
|
30
30
|
l && l.select();
|
|
31
|
-
},
|
|
31
|
+
}, P = (e, n) => {
|
|
32
32
|
const t = C(e);
|
|
33
33
|
if (!m(e))
|
|
34
34
|
throw new Error("Selected node is not a TableCellNode");
|
|
35
|
-
const o =
|
|
35
|
+
const o = D(e), r = t.getChildren().length, l = w(e);
|
|
36
36
|
let s = p(e);
|
|
37
37
|
const c = l.getChildren(), T = c.length;
|
|
38
38
|
for (let i = 0; i < T; i++) {
|
|
@@ -53,14 +53,14 @@ const b = 100, O = (e, n) => {
|
|
|
53
53
|
if (!m(e))
|
|
54
54
|
throw new Error("Selected node is not a TableCellNode");
|
|
55
55
|
const n = w(e), t = ((r = n.getFirstChild()) == null ? void 0 : r.getChildrenSize()) || 0, o = p(e);
|
|
56
|
-
t === 1 ?
|
|
56
|
+
t === 1 ? I(e) : E(n, o);
|
|
57
57
|
};
|
|
58
58
|
export {
|
|
59
59
|
O as createTable,
|
|
60
60
|
B as deleteColumn,
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
61
|
+
z as deleteRow,
|
|
62
|
+
I as deleteTable,
|
|
63
|
+
P as insertColumn,
|
|
64
|
+
F as insertRow
|
|
65
65
|
};
|
|
66
66
|
//# sourceMappingURL=helpers.js.map
|
|
@@ -1,36 +1,36 @@
|
|
|
1
1
|
import { jsxs as P, jsx as n } from "react/jsx-runtime";
|
|
2
2
|
import { u as y } from "../../../../LexicalComposerContext.prod-Dyvim1tK.js";
|
|
3
|
-
import {
|
|
4
|
-
import { useState as
|
|
5
|
-
import { g as b } from "../../../../LexicalTable.prod-
|
|
6
|
-
import { BlockFormatPlugin as
|
|
7
|
-
import { ListPlugin as
|
|
8
|
-
import { LinkPlugin as
|
|
9
|
-
import { HistoryPlugin as
|
|
10
|
-
import { T as
|
|
11
|
-
import { TableCellContextMenu as
|
|
12
|
-
import { s as
|
|
13
|
-
import { setScrollableContainers as
|
|
14
|
-
const
|
|
15
|
-
const [t] = y(), [i,
|
|
16
|
-
const e =
|
|
3
|
+
import { M as g, v as h, F as C } from "../../../../Lexical.prod-DSqOWcE1.js";
|
|
4
|
+
import { useState as E, useRef as L, useCallback as T, useEffect as m } from "react";
|
|
5
|
+
import { g as b } from "../../../../LexicalTable.prod-DEA4KRzX.js";
|
|
6
|
+
import { BlockFormatPlugin as N } from "../BlockFormatPlugin/BlockFormatPlugin.js";
|
|
7
|
+
import { ListPlugin as k } from "../ListPlugin/ListPlugin.js";
|
|
8
|
+
import { LinkPlugin as x } from "../LinkPlugin/LinkPlugin.js";
|
|
9
|
+
import { HistoryPlugin as B } from "../HistoryPlugin/HistoryPlugin.js";
|
|
10
|
+
import { T as S } from "../../../../TablePlugin-BBOjr3TX.js";
|
|
11
|
+
import { TableCellContextMenu as z } from "../TablePlugin/TableCellContextMenu/TableCellContextMenu.js";
|
|
12
|
+
import { s as A } from "../../../../RteEditor.module-DcvGRx3a.js";
|
|
13
|
+
import { setScrollableContainers as v, removeScrollableContainers as K } from "../../helpers.js";
|
|
14
|
+
const Q = ({ editorScrollPosition: d }) => {
|
|
15
|
+
const [t] = y(), [i, s] = E(null), u = L(null), f = T(() => {
|
|
16
|
+
const e = g();
|
|
17
17
|
if (h(e)) {
|
|
18
|
-
const
|
|
19
|
-
if (
|
|
20
|
-
const
|
|
21
|
-
|
|
18
|
+
const l = e.anchor.getNode(), a = b(l);
|
|
19
|
+
if (a) {
|
|
20
|
+
const p = t.getElementByKey(a.getKey()), c = p ? p.getBoundingClientRect() : { right: 0, bottom: 0, height: 0 };
|
|
21
|
+
s({ xPos: c.right, yPos: c.bottom, height: c.height });
|
|
22
22
|
} else
|
|
23
|
-
|
|
23
|
+
s(null);
|
|
24
24
|
}
|
|
25
|
-
}, [t]),
|
|
25
|
+
}, [t]), w = (e) => {
|
|
26
26
|
var r;
|
|
27
27
|
(r = u.current) == null || r.mutateTable(e);
|
|
28
28
|
}, o = () => {
|
|
29
29
|
t.update(() => {
|
|
30
|
-
const e =
|
|
30
|
+
const e = g();
|
|
31
31
|
if (h(e)) {
|
|
32
|
-
const
|
|
33
|
-
b(
|
|
32
|
+
const l = e.anchor.getNode();
|
|
33
|
+
b(l) && (C(null), s(null));
|
|
34
34
|
}
|
|
35
35
|
});
|
|
36
36
|
};
|
|
@@ -40,32 +40,32 @@ const O = ({ editorScrollPosition: d }) => {
|
|
|
40
40
|
f();
|
|
41
41
|
});
|
|
42
42
|
});
|
|
43
|
-
}, [t, f]), m(() => (
|
|
44
|
-
window.removeEventListener("scroll", o), window.removeEventListener("resize", o),
|
|
43
|
+
}, [t, f]), m(() => (v(o), window.addEventListener("scroll", o), window.addEventListener("resize", o), () => {
|
|
44
|
+
window.removeEventListener("scroll", o), window.removeEventListener("resize", o), K(o);
|
|
45
45
|
}), [t]), m(() => {
|
|
46
46
|
const e = () => {
|
|
47
|
-
|
|
47
|
+
v(o);
|
|
48
48
|
};
|
|
49
49
|
return window.addEventListener("keydown", e, { capture: !0 }), () => {
|
|
50
50
|
window.removeEventListener("keydown", e);
|
|
51
51
|
};
|
|
52
|
-
}, []), /* @__PURE__ */ P("div", { className:
|
|
53
|
-
/* @__PURE__ */ n(T, {}),
|
|
52
|
+
}, []), /* @__PURE__ */ P("div", { className: A.editor__toolbar, children: [
|
|
54
53
|
/* @__PURE__ */ n(N, {}),
|
|
55
|
-
/* @__PURE__ */ n(
|
|
54
|
+
/* @__PURE__ */ n(k, {}),
|
|
55
|
+
/* @__PURE__ */ n(S, { isActive: !!i, ref: u }),
|
|
56
56
|
i && /* @__PURE__ */ n(
|
|
57
|
-
|
|
57
|
+
z,
|
|
58
58
|
{
|
|
59
59
|
position: i,
|
|
60
60
|
parentScrollPosition: d,
|
|
61
|
-
onAction:
|
|
61
|
+
onAction: w
|
|
62
62
|
}
|
|
63
63
|
),
|
|
64
|
-
/* @__PURE__ */ n(
|
|
65
|
-
/* @__PURE__ */ n(
|
|
64
|
+
/* @__PURE__ */ n(x, { parentScrollPosition: d }),
|
|
65
|
+
/* @__PURE__ */ n(B, {})
|
|
66
66
|
] });
|
|
67
67
|
};
|
|
68
68
|
export {
|
|
69
|
-
|
|
69
|
+
Q as ToolBarPlugin
|
|
70
70
|
};
|
|
71
71
|
//# sourceMappingURL=ToolbarPlugin.js.map
|
|
@@ -3,7 +3,7 @@ import { BlockFormatPlugin as l } from "./BlockFormatPlugin/BlockFormatPlugin.js
|
|
|
3
3
|
import { ListPlugin as n } from "./ListPlugin/ListPlugin.js";
|
|
4
4
|
import { LinkPlugin as m, getLinkNodeTag as x } from "./LinkPlugin/LinkPlugin.js";
|
|
5
5
|
import { HistoryPlugin as p } from "./HistoryPlugin/HistoryPlugin.js";
|
|
6
|
-
import { T as a } from "../../../TablePlugin-
|
|
6
|
+
import { T as a } from "../../../TablePlugin-BBOjr3TX.js";
|
|
7
7
|
import { TableCellContextMenu as T } from "./TablePlugin/TableCellContextMenu/TableCellContextMenu.js";
|
|
8
8
|
export {
|
|
9
9
|
l as BlockFormatPlugin,
|