@uva-glass/component-library 1.53.0 → 1.55.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/AddTableFrom-CwnPli3F.js +162 -0
- package/dist/AddTableFrom-CwnPli3F.js.map +1 -0
- package/dist/{Lexical.prod-DNRTKPfN.js → Lexical.prod-BiuZHlIm.js} +927 -897
- package/dist/Lexical.prod-BiuZHlIm.js.map +1 -0
- package/dist/LexicalUtils.prod-BZOm66mY.js +94 -0
- package/dist/{LexicalUtils.prod-D_BPEjfg.js.map → LexicalUtils.prod-BZOm66mY.js.map} +1 -1
- package/dist/{ListPlugin-CgNBzfIl.js → ListPlugin-DFFbKLaN.js} +4 -4
- package/dist/{ListPlugin-CgNBzfIl.js.map → ListPlugin-DFFbKLaN.js.map} +1 -1
- package/dist/RteEditor.module-BBbfV1rk.js +24 -0
- package/dist/RteEditor.module-BBbfV1rk.js.map +1 -0
- package/dist/Sortable.module-BrgGu8qp.js +24 -0
- package/dist/Sortable.module-BrgGu8qp.js.map +1 -0
- package/dist/SortableProvider-Z0e0qeQT.js +152 -0
- package/dist/SortableProvider-Z0e0qeQT.js.map +1 -0
- package/dist/TablePlugin-CKJQiwra.js +1506 -0
- package/dist/TablePlugin-CKJQiwra.js.map +1 -0
- package/dist/assets/AddTableFrom.css +1 -0
- package/dist/assets/PageOverlay.css +1 -0
- package/dist/assets/RteEditor.css +1 -1
- package/dist/assets/Sortable.css +1 -0
- package/dist/assets/useFlyout.css +1 -1
- package/dist/components/CheckboxTree/CheckboxTree.js +11 -9
- package/dist/components/CheckboxTree/CheckboxTree.js.map +1 -1
- package/dist/components/Icon/icons/index.d.ts +3 -0
- package/dist/components/Icon/icons/index.js +18 -13
- package/dist/components/Icon/icons/index.js.map +1 -1
- package/dist/components/InputField/InputField.stories.js +13 -11
- 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 +4 -2
- package/dist/components/MultiSelect/components/MultiSelectHeader.js.map +1 -1
- package/dist/components/MultiSelect/index.js +1 -1
- package/dist/components/PageOverlay/PageOverlay.d.ts +25 -0
- package/dist/components/PageOverlay/PageOverlay.js +100 -0
- package/dist/components/PageOverlay/PageOverlay.js.map +1 -0
- package/dist/components/PageOverlay/PageOverlay.stories.d.ts +7 -0
- package/dist/components/PageOverlay/PageOverlay.stories.js +167 -0
- package/dist/components/PageOverlay/PageOverlay.stories.js.map +1 -0
- package/dist/components/PageOverlay/index.d.ts +1 -0
- package/dist/components/PageOverlay/index.js +5 -0
- package/dist/components/PageOverlay/index.js.map +1 -0
- package/dist/components/ProgrammeCard/ProgrammeCard.stories.js +26 -24
- package/dist/components/ProgrammeCard/ProgrammeCard.stories.js.map +1 -1
- package/dist/components/RteEditor/Plugins/BlockFormatPlugin/BlockFormatPlugin.js +2 -2
- package/dist/components/RteEditor/Plugins/HistoryPlugin/HistoryPlugin.js +18 -16
- package/dist/components/RteEditor/Plugins/HistoryPlugin/HistoryPlugin.js.map +1 -1
- package/dist/components/RteEditor/Plugins/LinkPlugin/AddLinkFrom.d.ts +12 -0
- package/dist/components/RteEditor/Plugins/LinkPlugin/AddLinkFrom.js +28 -0
- package/dist/components/RteEditor/Plugins/LinkPlugin/AddLinkFrom.js.map +1 -0
- package/dist/components/RteEditor/Plugins/LinkPlugin/LinkPlugin.js +49 -68
- 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 +3 -3
- package/dist/components/RteEditor/Plugins/ListPlugin/index.js +1 -1
- package/dist/components/RteEditor/Plugins/TablePlugin/AddTableFrom.d.ts +10 -0
- package/dist/components/RteEditor/Plugins/TablePlugin/AddTableFrom.js +25 -0
- package/dist/components/RteEditor/Plugins/TablePlugin/AddTableFrom.js.map +1 -0
- package/dist/components/RteEditor/Plugins/TablePlugin/TablePlugin.d.ts +1 -0
- package/dist/components/RteEditor/Plugins/TablePlugin/TablePlugin.js +29 -0
- package/dist/components/RteEditor/Plugins/TablePlugin/TablePlugin.js.map +1 -0
- package/dist/components/RteEditor/Plugins/TablePlugin/index.d.ts +1 -0
- package/dist/components/RteEditor/Plugins/TablePlugin/index.js +5 -0
- package/dist/components/RteEditor/Plugins/TablePlugin/index.js.map +1 -0
- package/dist/components/RteEditor/Plugins/ToolbarPlugin/ToolbarPlugin.js +26 -24
- package/dist/components/RteEditor/Plugins/ToolbarPlugin/ToolbarPlugin.js.map +1 -1
- package/dist/components/RteEditor/Plugins/index.d.ts +1 -0
- package/dist/components/RteEditor/Plugins/index.js +6 -4
- package/dist/components/RteEditor/Plugins/index.js.map +1 -1
- package/dist/components/RteEditor/RteEditor.js +559 -774
- package/dist/components/RteEditor/RteEditor.js.map +1 -1
- package/dist/components/RteEditor/UvaTheme/UvaTheme.d.ts +1 -0
- package/dist/components/RteEditor/UvaTheme/UvaTheme.js +5 -4
- package/dist/components/RteEditor/UvaTheme/UvaTheme.js.map +1 -1
- package/dist/components/RteEditor/hooks/useFlyout.d.ts +1 -0
- package/dist/components/RteEditor/hooks/useFlyout.js +18 -36
- package/dist/components/RteEditor/hooks/useFlyout.js.map +1 -1
- package/dist/components/Sortable/Sortable.d.ts +16 -0
- package/dist/components/Sortable/Sortable.js +27 -0
- package/dist/components/Sortable/Sortable.js.map +1 -0
- package/dist/components/Sortable/Sortable.stories.d.ts +7 -0
- package/dist/components/Sortable/Sortable.stories.js +53 -0
- package/dist/components/Sortable/Sortable.stories.js.map +1 -0
- package/dist/components/Sortable/SortableProvider.d.ts +23 -0
- package/dist/components/Sortable/SortableProvider.js +10 -0
- package/dist/components/Sortable/SortableProvider.js.map +1 -0
- package/dist/components/Sortable/actions.d.ts +49 -0
- package/dist/components/Sortable/actions.js +33 -0
- package/dist/components/Sortable/actions.js.map +1 -0
- package/dist/components/Sortable/components/SortableContainer.d.ts +7 -0
- package/dist/components/Sortable/components/SortableContainer.js +9 -0
- package/dist/components/Sortable/components/SortableContainer.js.map +1 -0
- package/dist/components/Sortable/components/SortableHandle.d.ts +4 -0
- package/dist/components/Sortable/components/SortableHandle.js +11 -0
- package/dist/components/Sortable/components/SortableHandle.js.map +1 -0
- package/dist/components/Sortable/components/SortableItem.d.ts +9 -0
- package/dist/components/Sortable/components/SortableItem.js +113 -0
- package/dist/components/Sortable/components/SortableItem.js.map +1 -0
- package/dist/components/Sortable/constants.d.ts +10 -0
- package/dist/components/Sortable/constants.js +14 -0
- package/dist/components/Sortable/constants.js.map +1 -0
- package/dist/components/Sortable/index.d.ts +1 -0
- package/dist/components/Sortable/index.js +5 -0
- package/dist/components/Sortable/index.js.map +1 -0
- package/dist/components/Sortable/sortableReducer.d.ts +24 -0
- package/dist/components/Sortable/sortableReducer.js +92 -0
- package/dist/components/Sortable/sortableReducer.js.map +1 -0
- package/dist/components/hooks/useOnClickOuside.d.ts +4 -0
- package/dist/components/hooks/useOnClickOuside.js +15 -0
- package/dist/components/hooks/useOnClickOuside.js.map +1 -0
- package/dist/components/index.d.ts +2 -0
- package/dist/components/index.js +45 -41
- package/dist/components/index.js.map +1 -1
- package/dist/{helpers-TSjo3aAv.js → helpers-CJF7fErD.js} +3 -3
- package/dist/{helpers-TSjo3aAv.js.map → helpers-CJF7fErD.js.map} +1 -1
- package/dist/index.js +45 -41
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
- package/dist/Lexical.prod-DNRTKPfN.js.map +0 -1
- package/dist/LexicalUtils.prod-D_BPEjfg.js +0 -64
- package/dist/MultiSelect-D1FnMER4.js +0 -53
- package/dist/MultiSelect-D1FnMER4.js.map +0 -1
- package/dist/RteEditor.module-BjGyWKhW.js +0 -26
- package/dist/RteEditor.module-BjGyWKhW.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as e, jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import { fn as a } from "../../index-MQ0yPLdl.js";
|
|
3
3
|
import { ProgrammeCard as o } from "./ProgrammeCard.js";
|
|
4
4
|
import { Container as n } from "../../storyComponents/Container/Container.js";
|
|
@@ -16,49 +16,51 @@ import "../IconButton/IconButton.js";
|
|
|
16
16
|
import "../Input/Input.js";
|
|
17
17
|
import "../InputField/InputField.js";
|
|
18
18
|
import "react-router-dom";
|
|
19
|
-
import "../../
|
|
19
|
+
import "../../AddTableFrom-CwnPli3F.js";
|
|
20
20
|
import { Repeater as i } from "../Repeater/Repeater.js";
|
|
21
21
|
import "../SelectListbox/SelectListbox.js";
|
|
22
22
|
import "../SelectListbox/SelectProvider.js";
|
|
23
|
-
|
|
23
|
+
import "../Sortable/components/SortableItem.js";
|
|
24
|
+
import "../../SortableProvider-Z0e0qeQT.js";
|
|
25
|
+
const l = "<ProgrammeCard key={key} header={header} details={details} onClick={onClickFunction} />", _ = {
|
|
24
26
|
title: "Atoms/ProgrammeCard",
|
|
25
27
|
component: o,
|
|
26
28
|
parameters: {
|
|
27
29
|
inspectComponent: o,
|
|
28
30
|
codeString: l
|
|
29
31
|
}
|
|
30
|
-
}, s = (t) => /* @__PURE__ */
|
|
31
|
-
|
|
32
|
+
}, s = (t) => /* @__PURE__ */ r(n, { size: "large", children: /* @__PURE__ */ r(o, { ...t }) }), p = s.bind({});
|
|
33
|
+
p.args = {
|
|
32
34
|
header: "This is my header",
|
|
33
35
|
details: "This is my details",
|
|
34
36
|
onClick: a()
|
|
35
37
|
};
|
|
36
|
-
const
|
|
37
|
-
|
|
38
|
-
header: /* @__PURE__ */
|
|
39
|
-
/* @__PURE__ */
|
|
40
|
-
/* @__PURE__ */
|
|
38
|
+
const d = s.bind({});
|
|
39
|
+
d.args = {
|
|
40
|
+
header: /* @__PURE__ */ e(i, { flexDirection: "row", gap: "150", children: [
|
|
41
|
+
/* @__PURE__ */ r(m, { name: "Envelope", size: 32 }),
|
|
42
|
+
/* @__PURE__ */ r("h2", { style: { margin: 0 }, children: "This is my header" })
|
|
41
43
|
] }),
|
|
42
|
-
details: /* @__PURE__ */
|
|
43
|
-
/* @__PURE__ */
|
|
44
|
-
/* @__PURE__ */
|
|
44
|
+
details: /* @__PURE__ */ e(i, { flexDirection: "row", gap: "150", children: [
|
|
45
|
+
/* @__PURE__ */ e(i, { flexDirection: "row", children: [
|
|
46
|
+
/* @__PURE__ */ r(m, { name: "FaceFrown" }),
|
|
45
47
|
"Details 1"
|
|
46
48
|
] }),
|
|
47
|
-
/* @__PURE__ */
|
|
48
|
-
/* @__PURE__ */
|
|
49
|
+
/* @__PURE__ */ e(i, { flexDirection: "row", children: [
|
|
50
|
+
/* @__PURE__ */ r(m, { name: "Heart" }),
|
|
49
51
|
"Details 2"
|
|
50
52
|
] }),
|
|
51
|
-
/* @__PURE__ */
|
|
52
|
-
/* @__PURE__ */
|
|
53
|
+
/* @__PURE__ */ e(i, { flexDirection: "row", children: [
|
|
54
|
+
/* @__PURE__ */ r(m, { name: "Sparkles" }),
|
|
53
55
|
"Details 3"
|
|
54
56
|
] })
|
|
55
57
|
] }),
|
|
56
58
|
onClick: a()
|
|
57
59
|
};
|
|
58
|
-
const c = (t) => /* @__PURE__ */
|
|
59
|
-
/* @__PURE__ */
|
|
60
|
-
/* @__PURE__ */
|
|
61
|
-
/* @__PURE__ */
|
|
60
|
+
const c = (t) => /* @__PURE__ */ r(n, { size: "large", children: /* @__PURE__ */ e(i, { children: [
|
|
61
|
+
/* @__PURE__ */ r(o, { ...t }),
|
|
62
|
+
/* @__PURE__ */ r(o, { ...t }),
|
|
63
|
+
/* @__PURE__ */ r(o, { ...t })
|
|
62
64
|
] }) }), h = c.bind({});
|
|
63
65
|
h.args = {
|
|
64
66
|
header: "This is my header",
|
|
@@ -67,8 +69,8 @@ h.args = {
|
|
|
67
69
|
};
|
|
68
70
|
export {
|
|
69
71
|
h as MultiProgrammeCards,
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
72
|
+
p as ProgrammeCardExample,
|
|
73
|
+
d as WithComplexContent,
|
|
74
|
+
_ as default
|
|
73
75
|
};
|
|
74
76
|
//# sourceMappingURL=ProgrammeCard.stories.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProgrammeCard.stories.js","sources":["../../../src/components/ProgrammeCard/ProgrammeCard.stories.tsx"],"sourcesContent":["import { fn } from '@storybook/test';\n\nimport type { Meta, StoryFn } from '@storybook/react';\nimport type { ProgrammeCardProps } from './ProgrammeCard';\n\nimport { ProgrammeCard } from './ProgrammeCard';\n\nimport { Container } from 'storyComponents/Container';\nimport { Icon, Repeater } from 'components';\n\nconst codeString = '<ProgrammeCard key={key} header={header} details={details} onClick={onClickFunction} />';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/ProgrammeCard',\n component: ProgrammeCard,\n parameters: {\n inspectComponent: ProgrammeCard,\n codeString: codeString,\n },\n} as Meta<ProgrammeCardProps>;\n\nconst Template: StoryFn<ProgrammeCardProps> = (args) => (\n <Container size=\"large\">\n <ProgrammeCard {...args} />\n </Container>\n);\n\nexport const ProgrammeCardExample = Template.bind({});\nProgrammeCardExample.args = {\n header: 'This is my header',\n details: 'This is my details',\n onClick: fn(),\n};\n\nexport const WithComplexContent = Template.bind({});\nWithComplexContent.args = {\n header: (\n <Repeater flexDirection=\"row\" gap=\"150\">\n <Icon name=\"Envelope\" size={32} />\n <h2 style={{ margin: 0 }}>This is my header</h2>\n </Repeater>\n ),\n details: (\n <Repeater flexDirection=\"row\" gap=\"150\">\n <Repeater flexDirection=\"row\">\n <Icon name=\"FaceFrown\" />\n Details 1\n </Repeater>\n <Repeater flexDirection=\"row\">\n <Icon name=\"Heart\" />\n Details 2\n </Repeater>\n <Repeater flexDirection=\"row\">\n <Icon name=\"Sparkles\" />\n Details 3\n </Repeater>\n </Repeater>\n ),\n onClick: fn(),\n};\n\nconst MultiProgrammeCardsTemplate: StoryFn<ProgrammeCardProps> = (args) => (\n <Container size=\"large\">\n <Repeater>\n <ProgrammeCard {...args} />\n <ProgrammeCard {...args} />\n <ProgrammeCard {...args} />\n </Repeater>\n </Container>\n);\n\nexport const MultiProgrammeCards = MultiProgrammeCardsTemplate.bind({});\nMultiProgrammeCards.args = {\n header: 'This is my header',\n details: 'This is my details',\n onClick: fn(),\n};\n"],"names":["codeString","ProgrammeCard_stories","ProgrammeCard","Template","args","jsx","Container","ProgrammeCardExample","fn","WithComplexContent","jsxs","Repeater","Icon","MultiProgrammeCardsTemplate","MultiProgrammeCards"],"mappings":"
|
|
1
|
+
{"version":3,"file":"ProgrammeCard.stories.js","sources":["../../../src/components/ProgrammeCard/ProgrammeCard.stories.tsx"],"sourcesContent":["import { fn } from '@storybook/test';\n\nimport type { Meta, StoryFn } from '@storybook/react';\nimport type { ProgrammeCardProps } from './ProgrammeCard';\n\nimport { ProgrammeCard } from './ProgrammeCard';\n\nimport { Container } from 'storyComponents/Container';\nimport { Icon, Repeater } from 'components';\n\nconst codeString = '<ProgrammeCard key={key} header={header} details={details} onClick={onClickFunction} />';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/ProgrammeCard',\n component: ProgrammeCard,\n parameters: {\n inspectComponent: ProgrammeCard,\n codeString: codeString,\n },\n} as Meta<ProgrammeCardProps>;\n\nconst Template: StoryFn<ProgrammeCardProps> = (args) => (\n <Container size=\"large\">\n <ProgrammeCard {...args} />\n </Container>\n);\n\nexport const ProgrammeCardExample = Template.bind({});\nProgrammeCardExample.args = {\n header: 'This is my header',\n details: 'This is my details',\n onClick: fn(),\n};\n\nexport const WithComplexContent = Template.bind({});\nWithComplexContent.args = {\n header: (\n <Repeater flexDirection=\"row\" gap=\"150\">\n <Icon name=\"Envelope\" size={32} />\n <h2 style={{ margin: 0 }}>This is my header</h2>\n </Repeater>\n ),\n details: (\n <Repeater flexDirection=\"row\" gap=\"150\">\n <Repeater flexDirection=\"row\">\n <Icon name=\"FaceFrown\" />\n Details 1\n </Repeater>\n <Repeater flexDirection=\"row\">\n <Icon name=\"Heart\" />\n Details 2\n </Repeater>\n <Repeater flexDirection=\"row\">\n <Icon name=\"Sparkles\" />\n Details 3\n </Repeater>\n </Repeater>\n ),\n onClick: fn(),\n};\n\nconst MultiProgrammeCardsTemplate: StoryFn<ProgrammeCardProps> = (args) => (\n <Container size=\"large\">\n <Repeater>\n <ProgrammeCard {...args} />\n <ProgrammeCard {...args} />\n <ProgrammeCard {...args} />\n </Repeater>\n </Container>\n);\n\nexport const MultiProgrammeCards = MultiProgrammeCardsTemplate.bind({});\nMultiProgrammeCards.args = {\n header: 'This is my header',\n details: 'This is my details',\n onClick: fn(),\n};\n"],"names":["codeString","ProgrammeCard_stories","ProgrammeCard","Template","args","jsx","Container","ProgrammeCardExample","fn","WithComplexContent","jsxs","Repeater","Icon","MultiProgrammeCardsTemplate","MultiProgrammeCards"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAUA,MAAMA,IAAa,2FAGJC,IAAA;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EACF;AACF,GAEMG,IAAwC,CAACC,MAC5C,gBAAAC,EAAAC,GAAA,EAAU,MAAK,SACd,UAAC,gBAAAD,EAAAH,GAAA,EAAe,GAAGE,EAAM,CAAA,EAC3B,CAAA,GAGWG,IAAuBJ,EAAS,KAAK,EAAE;AACpDI,EAAqB,OAAO;AAAA,EAC1B,QAAQ;AAAA,EACR,SAAS;AAAA,EACT,SAASC,EAAG;AACd;AAEO,MAAMC,IAAqBN,EAAS,KAAK,EAAE;AAClDM,EAAmB,OAAO;AAAA,EACxB,QACG,gBAAAC,EAAAC,GAAA,EAAS,eAAc,OAAM,KAAI,OAChC,UAAA;AAAA,IAAA,gBAAAN,EAACO,GAAK,EAAA,MAAK,YAAW,MAAM,IAAI;AAAA,sBAC/B,MAAG,EAAA,OAAO,EAAE,QAAQ,KAAK,UAAiB,qBAAA;AAAA,EAAA,GAC7C;AAAA,EAEF,SACG,gBAAAF,EAAAC,GAAA,EAAS,eAAc,OAAM,KAAI,OAChC,UAAA;AAAA,IAAC,gBAAAD,EAAAC,GAAA,EAAS,eAAc,OACtB,UAAA;AAAA,MAAC,gBAAAN,EAAAO,GAAA,EAAK,MAAK,YAAY,CAAA;AAAA,MAAE;AAAA,IAAA,GAE3B;AAAA,IACA,gBAAAF,EAACC,GAAS,EAAA,eAAc,OACtB,UAAA;AAAA,MAAC,gBAAAN,EAAAO,GAAA,EAAK,MAAK,QAAQ,CAAA;AAAA,MAAE;AAAA,IAAA,GAEvB;AAAA,IACA,gBAAAF,EAACC,GAAS,EAAA,eAAc,OACtB,UAAA;AAAA,MAAC,gBAAAN,EAAAO,GAAA,EAAK,MAAK,WAAW,CAAA;AAAA,MAAE;AAAA,IAAA,GAE1B;AAAA,EAAA,GACF;AAAA,EAEF,SAASJ,EAAG;AACd;AAEA,MAAMK,IAA2D,CAACT,MAChE,gBAAAC,EAACC,KAAU,MAAK,SACd,4BAACK,GACC,EAAA,UAAA;AAAA,EAAC,gBAAAN,EAAAH,GAAA,EAAe,GAAGE,GAAM;AAAA,EACzB,gBAAAC,EAACH,GAAe,EAAA,GAAGE,GAAM;AAAA,EACzB,gBAAAC,EAACH,GAAe,EAAA,GAAGE,GAAM;AAAA,EAC3B,CAAA,EACF,CAAA,GAGWU,IAAsBD,EAA4B,KAAK,EAAE;AACtEC,EAAoB,OAAO;AAAA,EACzB,QAAQ;AAAA,EACR,SAAS;AAAA,EACT,SAASN,EAAG;AACd;"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { u as m, d as n } from "../../../../Lexical.prod-
|
|
2
|
+
import { u as m, d as n } from "../../../../Lexical.prod-BiuZHlIm.js";
|
|
3
3
|
import { c as s } from "../../../../clsx-OuTLNxxd.js";
|
|
4
4
|
import { Icon as d } from "../../../Icon/Icon.js";
|
|
5
|
-
import { s as t } from "../../../../RteEditor.module-
|
|
5
|
+
import { s as t } from "../../../../RteEditor.module-BBbfV1rk.js";
|
|
6
6
|
const b = {
|
|
7
7
|
bold: "FormatBold",
|
|
8
8
|
italic: "FormatItalic"
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsxs as b, jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { c as
|
|
3
|
-
import { u as f, $ as _, K as h, h as C, g as U } from "../../../../Lexical.prod-
|
|
4
|
-
import { useState as n, useEffect as
|
|
5
|
-
import { Icon as
|
|
2
|
+
import { c as e } from "../../../../clsx-OuTLNxxd.js";
|
|
3
|
+
import { u as f, $ as _, K as h, h as C, g as U } from "../../../../Lexical.prod-BiuZHlIm.js";
|
|
4
|
+
import { useState as n, useEffect as m } from "react";
|
|
5
|
+
import { Icon as a } from "../../../Icon/Icon.js";
|
|
6
6
|
import "../../../Buttons/Button.js";
|
|
7
7
|
import "../../../Buttons/LinkButton.js";
|
|
8
8
|
import "@react-aria/button";
|
|
@@ -15,48 +15,50 @@ import "../../../IconButton/IconButton.js";
|
|
|
15
15
|
import "../../../Input/Input.js";
|
|
16
16
|
import "../../../InputField/InputField.js";
|
|
17
17
|
import "react-router-dom";
|
|
18
|
-
import "../../../../
|
|
19
|
-
import { s as t } from "../../../../RteEditor.module-
|
|
18
|
+
import "../../../../AddTableFrom-CwnPli3F.js";
|
|
19
|
+
import { s as t } from "../../../../RteEditor.module-BBbfV1rk.js";
|
|
20
20
|
import "../../../SelectListbox/SelectListbox.js";
|
|
21
21
|
import "../../../SelectListbox/SelectProvider.js";
|
|
22
|
-
|
|
22
|
+
import "../../../Sortable/components/SortableItem.js";
|
|
23
|
+
import "../../../../SortableProvider-Z0e0qeQT.js";
|
|
24
|
+
const J = () => {
|
|
23
25
|
const [o] = f(), [s, d] = n(!1), [l, p] = n(!1), c = () => {
|
|
24
26
|
o.dispatchCommand(C, void 0);
|
|
25
27
|
}, u = () => {
|
|
26
28
|
o.dispatchCommand(U, void 0);
|
|
27
29
|
};
|
|
28
|
-
return
|
|
30
|
+
return m(() => o.registerCommand(
|
|
29
31
|
_,
|
|
30
|
-
(
|
|
32
|
+
(i) => (d(i), !1),
|
|
31
33
|
1
|
|
32
|
-
), [o]),
|
|
34
|
+
), [o]), m(() => o.registerCommand(
|
|
33
35
|
h,
|
|
34
|
-
(
|
|
36
|
+
(i) => (p(i), !1),
|
|
35
37
|
1
|
|
36
38
|
), [o]), /* @__PURE__ */ b("div", { className: t["editor__toolbar-button-group"], children: [
|
|
37
39
|
/* @__PURE__ */ r(
|
|
38
40
|
"button",
|
|
39
41
|
{
|
|
40
42
|
onClick: c,
|
|
41
|
-
className:
|
|
43
|
+
className: e(t["editor__toolbar-button"], t["editor__toolbar-button--undo"]),
|
|
42
44
|
"aria-label": "Undo",
|
|
43
45
|
disabled: !s,
|
|
44
|
-
children: /* @__PURE__ */ r(
|
|
46
|
+
children: /* @__PURE__ */ r(a, { name: "Undo", size: 20 })
|
|
45
47
|
}
|
|
46
48
|
),
|
|
47
49
|
/* @__PURE__ */ r(
|
|
48
50
|
"button",
|
|
49
51
|
{
|
|
50
52
|
onClick: u,
|
|
51
|
-
className:
|
|
53
|
+
className: e(t["editor__toolbar-button"], t["editor__toolbar-button--redo"]),
|
|
52
54
|
"aria-label": "Undo",
|
|
53
55
|
disabled: !l,
|
|
54
|
-
children: /* @__PURE__ */ r(
|
|
56
|
+
children: /* @__PURE__ */ r(a, { name: "Redo", size: 20 })
|
|
55
57
|
}
|
|
56
58
|
)
|
|
57
59
|
] });
|
|
58
60
|
};
|
|
59
61
|
export {
|
|
60
|
-
|
|
62
|
+
J as HistoryPlugin
|
|
61
63
|
};
|
|
62
64
|
//# sourceMappingURL=HistoryPlugin.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HistoryPlugin.js","sources":["../../../../../src/components/RteEditor/Plugins/HistoryPlugin/HistoryPlugin.tsx"],"sourcesContent":["import clsx from 'clsx';\nimport { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext';\nimport { CAN_UNDO_COMMAND, CAN_REDO_COMMAND, UNDO_COMMAND, REDO_COMMAND } from 'lexical';\nimport { useEffect, useState } from 'react';\n\nimport { Icon } from 'components';\nimport styles from 'components/RteEditor/RteEditor.module.css';\n\nexport const HistoryPlugin = () => {\n const [editor] = useLexicalComposerContext();\n const [canUndo, setCanUndo] = useState(false);\n const [canRedo, setCanRedo] = useState(false);\n\n const handleUndo = () => {\n editor.dispatchCommand(UNDO_COMMAND, undefined);\n };\n\n const handleRedo = () => {\n editor.dispatchCommand(REDO_COMMAND, undefined);\n };\n\n useEffect(() => {\n return editor.registerCommand<boolean>(\n CAN_UNDO_COMMAND,\n (payload) => {\n setCanUndo(payload);\n return false;\n },\n 1\n );\n }, [editor]);\n\n useEffect(() => {\n return editor.registerCommand<boolean>(\n CAN_REDO_COMMAND,\n (payload) => {\n setCanRedo(payload);\n return false;\n },\n 1\n );\n }, [editor]);\n\n return (\n <div className={styles['editor__toolbar-button-group']}>\n <button\n onClick={handleUndo}\n className={clsx(styles['editor__toolbar-button'], styles[`editor__toolbar-button--undo`])}\n aria-label={`Undo`}\n disabled={!canUndo}\n >\n <Icon name=\"Undo\" size={20} />\n </button>\n <button\n onClick={handleRedo}\n className={clsx(styles['editor__toolbar-button'], styles[`editor__toolbar-button--redo`])}\n aria-label={`Undo`}\n disabled={!canRedo}\n >\n <Icon name=\"Redo\" size={20} />\n </button>\n </div>\n );\n};\n"],"names":["HistoryPlugin","editor","useLexicalComposerContext","canUndo","setCanUndo","useState","canRedo","setCanRedo","handleUndo","UNDO_COMMAND","handleRedo","REDO_COMMAND","useEffect","CAN_UNDO_COMMAND","payload","CAN_REDO_COMMAND","jsxs","styles","jsx","clsx","Icon"],"mappings":"
|
|
1
|
+
{"version":3,"file":"HistoryPlugin.js","sources":["../../../../../src/components/RteEditor/Plugins/HistoryPlugin/HistoryPlugin.tsx"],"sourcesContent":["import clsx from 'clsx';\nimport { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext';\nimport { CAN_UNDO_COMMAND, CAN_REDO_COMMAND, UNDO_COMMAND, REDO_COMMAND } from 'lexical';\nimport { useEffect, useState } from 'react';\n\nimport { Icon } from 'components';\nimport styles from 'components/RteEditor/RteEditor.module.css';\n\nexport const HistoryPlugin = () => {\n const [editor] = useLexicalComposerContext();\n const [canUndo, setCanUndo] = useState(false);\n const [canRedo, setCanRedo] = useState(false);\n\n const handleUndo = () => {\n editor.dispatchCommand(UNDO_COMMAND, undefined);\n };\n\n const handleRedo = () => {\n editor.dispatchCommand(REDO_COMMAND, undefined);\n };\n\n useEffect(() => {\n return editor.registerCommand<boolean>(\n CAN_UNDO_COMMAND,\n (payload) => {\n setCanUndo(payload);\n return false;\n },\n 1\n );\n }, [editor]);\n\n useEffect(() => {\n return editor.registerCommand<boolean>(\n CAN_REDO_COMMAND,\n (payload) => {\n setCanRedo(payload);\n return false;\n },\n 1\n );\n }, [editor]);\n\n return (\n <div className={styles['editor__toolbar-button-group']}>\n <button\n onClick={handleUndo}\n className={clsx(styles['editor__toolbar-button'], styles[`editor__toolbar-button--undo`])}\n aria-label={`Undo`}\n disabled={!canUndo}\n >\n <Icon name=\"Undo\" size={20} />\n </button>\n <button\n onClick={handleRedo}\n className={clsx(styles['editor__toolbar-button'], styles[`editor__toolbar-button--redo`])}\n aria-label={`Undo`}\n disabled={!canRedo}\n >\n <Icon name=\"Redo\" size={20} />\n </button>\n </div>\n );\n};\n"],"names":["HistoryPlugin","editor","useLexicalComposerContext","canUndo","setCanUndo","useState","canRedo","setCanRedo","handleUndo","UNDO_COMMAND","handleRedo","REDO_COMMAND","useEffect","CAN_UNDO_COMMAND","payload","CAN_REDO_COMMAND","jsxs","styles","jsx","clsx","Icon"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAQO,MAAMA,IAAgB,MAAM;AAC3B,QAAA,CAACC,CAAM,IAAIC,KACX,CAACC,GAASC,CAAU,IAAIC,EAAS,EAAK,GACtC,CAACC,GAASC,CAAU,IAAIF,EAAS,EAAK,GAEtCG,IAAa,MAAM;AAChB,IAAAP,EAAA,gBAAgBQ,GAAc,MAAS;AAAA,EAAA,GAG1CC,IAAa,MAAM;AAChB,IAAAT,EAAA,gBAAgBU,GAAc,MAAS;AAAA,EAAA;AAGhD,SAAAC,EAAU,MACDX,EAAO;AAAA,IACZY;AAAAA,IACA,CAACC,OACCV,EAAWU,CAAO,GACX;AAAA,IAET;AAAA,EAAA,GAED,CAACb,CAAM,CAAC,GAEXW,EAAU,MACDX,EAAO;AAAA,IACZc;AAAAA,IACA,CAACD,OACCP,EAAWO,CAAO,GACX;AAAA,IAET;AAAA,EAAA,GAED,CAACb,CAAM,CAAC,GAGR,gBAAAe,EAAA,OAAA,EAAI,WAAWC,EAAO,8BAA8B,GACnD,UAAA;AAAA,IAAA,gBAAAC;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,SAASV;AAAA,QACT,WAAWW,EAAKF,EAAO,wBAAwB,GAAGA,EAAO,8BAA8B,CAAC;AAAA,QACxF,cAAY;AAAA,QACZ,UAAU,CAACd;AAAA,QAEX,UAAC,gBAAAe,EAAAE,GAAA,EAAK,MAAK,QAAO,MAAM,IAAI;AAAA,MAAA;AAAA,IAC9B;AAAA,IACA,gBAAAF;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,SAASR;AAAA,QACT,WAAWS,EAAKF,EAAO,wBAAwB,GAAGA,EAAO,8BAA8B,CAAC;AAAA,QACxF,cAAY;AAAA,QACZ,UAAU,CAACX;AAAA,QAEX,UAAC,gBAAAY,EAAAE,GAAA,EAAK,MAAK,QAAO,MAAM,IAAI;AAAA,MAAA;AAAA,IAC9B;AAAA,EACF,EAAA,CAAA;AAEJ;"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { LinkType } from 'components/RteEditor/Plugins/ToolbarPlugin/ToolbarPlugin';
|
|
2
|
+
interface AddLinkFormProps {
|
|
3
|
+
onCloseHandler: () => void;
|
|
4
|
+
onSaveHandler: (url: string, target: string) => void;
|
|
5
|
+
isLink: LinkType;
|
|
6
|
+
}
|
|
7
|
+
export interface addLinkFormMethods {
|
|
8
|
+
clearForm: () => void;
|
|
9
|
+
focusFirstField: () => void;
|
|
10
|
+
}
|
|
11
|
+
export declare const AddLinkForm: import('react').ForwardRefExoticComponent<AddLinkFormProps & import('react').RefAttributes<unknown>>;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import "react/jsx-runtime";
|
|
2
|
+
import "react";
|
|
3
|
+
import "../../../../helpers-CJF7fErD.js";
|
|
4
|
+
import { A as v } from "../../../../AddTableFrom-CwnPli3F.js";
|
|
5
|
+
import "../../../Buttons/Button.js";
|
|
6
|
+
import "../../../Buttons/LinkButton.js";
|
|
7
|
+
import "@react-aria/button";
|
|
8
|
+
import "../../../Checkbox/Checkbox.js";
|
|
9
|
+
import "../../../Label/Label.js";
|
|
10
|
+
import "@react-aria/dialog";
|
|
11
|
+
import "@react-aria/focus";
|
|
12
|
+
import "@react-aria/overlays";
|
|
13
|
+
import "../../../OverlayCloseButton/OverlayCloseButton.js";
|
|
14
|
+
import "../../../FeedbackBox/FeedbackBox.js";
|
|
15
|
+
import "../../../FormField/FormField.js";
|
|
16
|
+
import "../../../GridRow/GridRow.js";
|
|
17
|
+
import "../../../IconButton/IconButton.js";
|
|
18
|
+
import "../../../Input/Input.js";
|
|
19
|
+
import "../../../InputField/InputField.js";
|
|
20
|
+
import "react-router-dom";
|
|
21
|
+
import "../../../SelectListbox/SelectListbox.js";
|
|
22
|
+
import "../../../SelectListbox/SelectProvider.js";
|
|
23
|
+
import "../../../Sortable/components/SortableItem.js";
|
|
24
|
+
import "../../../../SortableProvider-Z0e0qeQT.js";
|
|
25
|
+
export {
|
|
26
|
+
v as AddLinkForm
|
|
27
|
+
};
|
|
28
|
+
//# sourceMappingURL=AddLinkFrom.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AddLinkFrom.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,98 +1,79 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { u as
|
|
3
|
-
import { c as
|
|
4
|
-
import { U as
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
1
|
+
import { jsxs as c, jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import { u as F } from "../../../../Lexical.prod-BiuZHlIm.js";
|
|
3
|
+
import { c as p } from "../../../../clsx-OuTLNxxd.js";
|
|
4
|
+
import { U as u } from "../../../../helpers-CJF7fErD.js";
|
|
5
|
+
import { useRef as d, useEffect as y } from "react";
|
|
6
|
+
import { A as L } from "../../../../AddTableFrom-CwnPli3F.js";
|
|
7
|
+
import { useFlyout as N } from "../../hooks/useFlyout.js";
|
|
8
|
+
import { Icon as f } from "../../../Icon/Icon.js";
|
|
9
|
+
import "../../../Buttons/Button.js";
|
|
9
10
|
import "../../../Buttons/LinkButton.js";
|
|
10
11
|
import "@react-aria/button";
|
|
11
|
-
import { Checkbox as V } from "../../../Checkbox/Checkbox.js";
|
|
12
|
-
import { Label as y } from "../../../Label/Label.js";
|
|
13
12
|
import "@react-aria/dialog";
|
|
14
13
|
import "@react-aria/focus";
|
|
15
14
|
import "@react-aria/overlays";
|
|
16
15
|
import "../../../OverlayCloseButton/OverlayCloseButton.js";
|
|
17
|
-
import { FeedbackBox as j } from "../../../FeedbackBox/FeedbackBox.js";
|
|
18
|
-
import { FormField as C } from "../../../FormField/FormField.js";
|
|
19
16
|
import "../../../GridRow/GridRow.js";
|
|
20
17
|
import "../../../IconButton/IconButton.js";
|
|
21
18
|
import "../../../Input/Input.js";
|
|
22
|
-
import
|
|
19
|
+
import "../../../InputField/InputField.js";
|
|
23
20
|
import "react-router-dom";
|
|
24
|
-
import "../../../../
|
|
25
|
-
import { s as t } from "../../../../RteEditor.module-BjGyWKhW.js";
|
|
21
|
+
import { s as o } from "../../../../RteEditor.module-BBbfV1rk.js";
|
|
26
22
|
import "../../../SelectListbox/SelectListbox.js";
|
|
27
23
|
import "../../../SelectListbox/SelectProvider.js";
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
},
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
/* @__PURE__ */ r(z, { id: "lnikUrl", ref: e, placeholder: "http(s)://" }),
|
|
49
|
-
a && /* @__PURE__ */ r(j, { level: "error", feedback: a })
|
|
50
|
-
] }),
|
|
51
|
-
/* @__PURE__ */ i(C, { inline: !0, children: [
|
|
52
|
-
/* @__PURE__ */ r(V, { id: "linkTarget", onChange: x, checked: c }),
|
|
53
|
-
/* @__PURE__ */ r(y, { htmlFor: "linkTarget", children: "Open in nieuwe window" })
|
|
54
|
-
] }),
|
|
55
|
-
/* @__PURE__ */ i("div", { className: t["editor__linkform-footer"], children: [
|
|
56
|
-
/* @__PURE__ */ r(F, { variant: "secondary", onClick: u, children: "Annuleer" }),
|
|
57
|
-
/* @__PURE__ */ r(F, { variant: "primary", onClick: w, children: "Link" })
|
|
58
|
-
] })
|
|
59
|
-
] })
|
|
24
|
+
import "../../../Sortable/components/SortableItem.js";
|
|
25
|
+
import "../../../../SortableProvider-Z0e0qeQT.js";
|
|
26
|
+
const C = 200, W = ({ isLink: l = { active: !1, url: "", target: "_self" } }) => {
|
|
27
|
+
const [m] = F(), { flyout: b, showFlyout: _, closeFlyout: s, isVisible: a } = N(), e = d(), n = d(!1), k = (t, r) => {
|
|
28
|
+
m.dispatchCommand(u, {
|
|
29
|
+
url: t,
|
|
30
|
+
target: r
|
|
31
|
+
}), s();
|
|
32
|
+
}, h = () => {
|
|
33
|
+
m.dispatchCommand(u, null);
|
|
34
|
+
}, v = {
|
|
35
|
+
children: /* @__PURE__ */ i(
|
|
36
|
+
L,
|
|
37
|
+
{
|
|
38
|
+
isLink: l,
|
|
39
|
+
onCloseHandler: s,
|
|
40
|
+
onSaveHandler: (t, r) => k(t, r),
|
|
41
|
+
ref: e
|
|
42
|
+
}
|
|
43
|
+
)
|
|
60
44
|
};
|
|
61
|
-
return
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
}, [n, o.url, o.target]), /* @__PURE__ */ i("div", { className: t["editor__toolbar-button-group"], children: [
|
|
68
|
-
/* @__PURE__ */ i("div", { className: t["editor__toolbar-button-flyoutwrapper"], children: [
|
|
69
|
-
/* @__PURE__ */ r(
|
|
45
|
+
return y(() => {
|
|
46
|
+
var t, r;
|
|
47
|
+
a ? (n.current = !0, (r = e.current) == null || r.focusFirstField()) : ((t = e.current) == null || t.clearForm(), setTimeout(() => n.current = !1, C));
|
|
48
|
+
}, [e, a]), /* @__PURE__ */ c("div", { className: o["editor__toolbar-button-group"], children: [
|
|
49
|
+
/* @__PURE__ */ c("div", { className: o["editor__toolbar-button-flyoutwrapper"], children: [
|
|
50
|
+
/* @__PURE__ */ i(
|
|
70
51
|
"button",
|
|
71
52
|
{
|
|
72
|
-
onClick: () => n
|
|
73
|
-
className:
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
53
|
+
onClick: () => !n.current && _(v),
|
|
54
|
+
className: p(
|
|
55
|
+
o["editor__toolbar-button"],
|
|
56
|
+
o["editor__toolbar-button--link"],
|
|
57
|
+
l.active && o["editor__toolbar-button--active"]
|
|
77
58
|
),
|
|
78
59
|
"aria-label": "Format link",
|
|
79
|
-
children: /* @__PURE__ */
|
|
60
|
+
children: /* @__PURE__ */ i(f, { name: "Link", size: 20 })
|
|
80
61
|
}
|
|
81
62
|
),
|
|
82
|
-
|
|
63
|
+
b
|
|
83
64
|
] }),
|
|
84
|
-
/* @__PURE__ */
|
|
65
|
+
/* @__PURE__ */ i(
|
|
85
66
|
"button",
|
|
86
67
|
{
|
|
87
|
-
onClick:
|
|
88
|
-
className:
|
|
68
|
+
onClick: h,
|
|
69
|
+
className: p(o["editor__toolbar-button"], o["editor__toolbar-button--link"]),
|
|
89
70
|
"aria-label": "Remove link",
|
|
90
|
-
children: /* @__PURE__ */
|
|
71
|
+
children: /* @__PURE__ */ i(f, { name: "LinkSlash", size: 20 })
|
|
91
72
|
}
|
|
92
73
|
)
|
|
93
74
|
] });
|
|
94
75
|
};
|
|
95
76
|
export {
|
|
96
|
-
|
|
77
|
+
W as LinkPlugin
|
|
97
78
|
};
|
|
98
79
|
//# sourceMappingURL=LinkPlugin.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LinkPlugin.js","sources":["../../../../../src/components/RteEditor/Plugins/LinkPlugin/LinkPlugin.tsx"],"sourcesContent":["import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext';\nimport clsx from 'clsx';\nimport { TOGGLE_LINK_COMMAND } from '@lexical/link';\nimport { useEffect, useRef
|
|
1
|
+
{"version":3,"file":"LinkPlugin.js","sources":["../../../../../src/components/RteEditor/Plugins/LinkPlugin/LinkPlugin.tsx"],"sourcesContent":["import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext';\nimport clsx from 'clsx';\nimport { TOGGLE_LINK_COMMAND } from '@lexical/link';\nimport { useEffect, useRef } from 'react';\n\nimport type { LinkType } from 'components/RteEditor/Plugins/ToolbarPlugin/ToolbarPlugin';\nimport type { addLinkFormMethods } from './AddLinkFrom';\n\nimport { AddLinkForm } from './AddLinkFrom';\n\nimport { useFlyout } from 'components/RteEditor/hooks';\nimport { Icon } from 'components';\nimport styles from 'components/RteEditor/RteEditor.module.css';\ninterface LinkPluginProps {\n isLink: LinkType;\n}\n\nconst PREVENT_OPEN_DELAY = 200;\n\nexport const LinkPlugin = ({ isLink = { active: false, url: '', target: '_self' } }: LinkPluginProps) => {\n const [editor] = useLexicalComposerContext();\n const { flyout, showFlyout, closeFlyout, isVisible } = useFlyout();\n const addLinkForm = useRef<addLinkFormMethods>();\n const preventOpen = useRef(false);\n\n const insertLink = (url: string, target: string) => {\n editor.dispatchCommand(TOGGLE_LINK_COMMAND, {\n url,\n target,\n });\n\n closeFlyout();\n };\n\n const removeLink = (): void => {\n editor.dispatchCommand(TOGGLE_LINK_COMMAND, null);\n };\n\n const flyoutOptions = {\n children: (\n <AddLinkForm\n isLink={isLink}\n onCloseHandler={closeFlyout}\n onSaveHandler={(url, target) => insertLink(url, target)}\n ref={addLinkForm}\n />\n ),\n };\n\n useEffect(() => {\n if (!isVisible) {\n addLinkForm.current?.clearForm();\n setTimeout(() => (preventOpen.current = false), PREVENT_OPEN_DELAY);\n } else {\n preventOpen.current = true;\n addLinkForm.current?.focusFirstField();\n }\n }, [addLinkForm, isVisible]);\n\n return (\n <div className={styles['editor__toolbar-button-group']}>\n <div className={styles['editor__toolbar-button-flyoutwrapper']}>\n <button\n onClick={() => !preventOpen.current && showFlyout(flyoutOptions)}\n className={clsx(\n styles['editor__toolbar-button'],\n styles[`editor__toolbar-button--link`],\n isLink.active && styles['editor__toolbar-button--active']\n )}\n aria-label={`Format link`}\n >\n <Icon name=\"Link\" size={20} />\n </button>\n {flyout}\n </div>\n <button\n onClick={removeLink}\n className={clsx(styles['editor__toolbar-button'], styles[`editor__toolbar-button--link`])}\n aria-label={`Remove link`}\n >\n <Icon name=\"LinkSlash\" size={20} />\n </button>\n </div>\n );\n};\n"],"names":["PREVENT_OPEN_DELAY","LinkPlugin","isLink","editor","useLexicalComposerContext","flyout","showFlyout","closeFlyout","isVisible","useFlyout","addLinkForm","useRef","preventOpen","insertLink","url","target","TOGGLE_LINK_COMMAND","removeLink","flyoutOptions","jsx","AddLinkForm","useEffect","_b","_a","jsxs","styles","clsx","Icon"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAiBA,MAAMA,IAAqB,KAEdC,IAAa,CAAC,EAAE,QAAAC,IAAS,EAAE,QAAQ,IAAO,KAAK,IAAI,QAAQ,QAAQ,QAAyB;AACjG,QAAA,CAACC,CAAM,IAAIC,KACX,EAAE,QAAAC,GAAQ,YAAAC,GAAY,aAAAC,GAAa,WAAAC,EAAA,IAAcC,KACjDC,IAAcC,KACdC,IAAcD,EAAO,EAAK,GAE1BE,IAAa,CAACC,GAAaC,MAAmB;AAClD,IAAAZ,EAAO,gBAAgBa,GAAqB;AAAA,MAC1C,KAAAF;AAAA,MACA,QAAAC;AAAA,IAAA,CACD,GAEWR;EAAA,GAGRU,IAAa,MAAY;AACtB,IAAAd,EAAA,gBAAgBa,GAAqB,IAAI;AAAA,EAAA,GAG5CE,IAAgB;AAAA,IACpB,UACE,gBAAAC;AAAA,MAACC;AAAA,MAAA;AAAA,QACC,QAAAlB;AAAA,QACA,gBAAgBK;AAAA,QAChB,eAAe,CAACO,GAAKC,MAAWF,EAAWC,GAAKC,CAAM;AAAA,QACtD,KAAKL;AAAA,MAAA;AAAA,IACP;AAAA,EAAA;AAIJ,SAAAW,EAAU,MAAM;;AACd,IAAKb,KAIHI,EAAY,UAAU,KACtBU,IAAAZ,EAAY,YAAZ,QAAAY,EAAqB,uBAJrBC,IAAAb,EAAY,YAAZ,QAAAa,EAAqB,aACrB,WAAW,MAAOX,EAAY,UAAU,IAAQZ,CAAkB;AAAA,EAIpE,GACC,CAACU,GAAaF,CAAS,CAAC,GAGxB,gBAAAgB,EAAA,OAAA,EAAI,WAAWC,EAAO,8BAA8B,GACnD,UAAA;AAAA,IAAA,gBAAAD,EAAC,OAAI,EAAA,WAAWC,EAAO,sCAAsC,GAC3D,UAAA;AAAA,MAAA,gBAAAN;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,SAAS,MAAM,CAACP,EAAY,WAAWN,EAAWY,CAAa;AAAA,UAC/D,WAAWQ;AAAA,YACTD,EAAO,wBAAwB;AAAA,YAC/BA,EAAO,8BAA8B;AAAA,YACrCvB,EAAO,UAAUuB,EAAO,gCAAgC;AAAA,UAC1D;AAAA,UACA,cAAY;AAAA,UAEZ,UAAC,gBAAAN,EAAAQ,GAAA,EAAK,MAAK,QAAO,MAAM,IAAI;AAAA,QAAA;AAAA,MAC9B;AAAA,MACCtB;AAAA,IAAA,GACH;AAAA,IACA,gBAAAc;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,SAASF;AAAA,QACT,WAAWS,EAAKD,EAAO,wBAAwB,GAAGA,EAAO,8BAA8B,CAAC;AAAA,QACxF,cAAY;AAAA,QAEZ,UAAC,gBAAAN,EAAAQ,GAAA,EAAK,MAAK,aAAY,MAAM,IAAI;AAAA,MAAA;AAAA,IACnC;AAAA,EACF,EAAA,CAAA;AAEJ;"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
|
-
import "../../../../Lexical.prod-
|
|
3
|
-
import { L as a } from "../../../../ListPlugin-
|
|
2
|
+
import "../../../../Lexical.prod-BiuZHlIm.js";
|
|
3
|
+
import { L as a } from "../../../../ListPlugin-DFFbKLaN.js";
|
|
4
4
|
import "react";
|
|
5
5
|
import "../../../../clsx-OuTLNxxd.js";
|
|
6
6
|
import "../../../Icon/Icon.js";
|
|
7
|
-
import "../../../../RteEditor.module-
|
|
7
|
+
import "../../../../RteEditor.module-BBbfV1rk.js";
|
|
8
8
|
export {
|
|
9
9
|
a as ListPlugin
|
|
10
10
|
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
interface AddTableFormProps {
|
|
2
|
+
onCloseHandler: () => void;
|
|
3
|
+
onSaveHandler: (nrfOfRows: number, nrOfColumns: number) => void;
|
|
4
|
+
}
|
|
5
|
+
export interface addTableForm {
|
|
6
|
+
clearForm: () => void;
|
|
7
|
+
focusFirstField: () => void;
|
|
8
|
+
}
|
|
9
|
+
export declare const AddTableForm: import('react').ForwardRefExoticComponent<AddTableFormProps & import('react').RefAttributes<unknown>>;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import "react/jsx-runtime";
|
|
2
|
+
import "react";
|
|
3
|
+
import { a as n } from "../../../../AddTableFrom-CwnPli3F.js";
|
|
4
|
+
import "../../../Buttons/Button.js";
|
|
5
|
+
import "../../../Buttons/LinkButton.js";
|
|
6
|
+
import "@react-aria/button";
|
|
7
|
+
import "../../../Label/Label.js";
|
|
8
|
+
import "@react-aria/dialog";
|
|
9
|
+
import "@react-aria/focus";
|
|
10
|
+
import "@react-aria/overlays";
|
|
11
|
+
import "../../../OverlayCloseButton/OverlayCloseButton.js";
|
|
12
|
+
import "../../../FormField/FormField.js";
|
|
13
|
+
import "../../../GridRow/GridRow.js";
|
|
14
|
+
import "../../../IconButton/IconButton.js";
|
|
15
|
+
import "../../../Input/Input.js";
|
|
16
|
+
import "../../../InputField/InputField.js";
|
|
17
|
+
import "react-router-dom";
|
|
18
|
+
import "../../../SelectListbox/SelectListbox.js";
|
|
19
|
+
import "../../../SelectListbox/SelectProvider.js";
|
|
20
|
+
import "../../../Sortable/components/SortableItem.js";
|
|
21
|
+
import "../../../../SortableProvider-Z0e0qeQT.js";
|
|
22
|
+
export {
|
|
23
|
+
n as AddTableForm
|
|
24
|
+
};
|
|
25
|
+
//# sourceMappingURL=AddTableFrom.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AddTableFrom.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const TablePlugin: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import "react/jsx-runtime";
|
|
2
|
+
import "../../../../Lexical.prod-BiuZHlIm.js";
|
|
3
|
+
import "../../../../clsx-OuTLNxxd.js";
|
|
4
|
+
import { T as y } from "../../../../TablePlugin-CKJQiwra.js";
|
|
5
|
+
import "react";
|
|
6
|
+
import "../../../../AddTableFrom-CwnPli3F.js";
|
|
7
|
+
import "../../hooks/useFlyout.js";
|
|
8
|
+
import "../../../Icon/Icon.js";
|
|
9
|
+
import "../../../Buttons/Button.js";
|
|
10
|
+
import "../../../Buttons/LinkButton.js";
|
|
11
|
+
import "@react-aria/button";
|
|
12
|
+
import "@react-aria/dialog";
|
|
13
|
+
import "@react-aria/focus";
|
|
14
|
+
import "@react-aria/overlays";
|
|
15
|
+
import "../../../OverlayCloseButton/OverlayCloseButton.js";
|
|
16
|
+
import "../../../GridRow/GridRow.js";
|
|
17
|
+
import "../../../IconButton/IconButton.js";
|
|
18
|
+
import "../../../Input/Input.js";
|
|
19
|
+
import "../../../InputField/InputField.js";
|
|
20
|
+
import "react-router-dom";
|
|
21
|
+
import "../../../../RteEditor.module-BBbfV1rk.js";
|
|
22
|
+
import "../../../SelectListbox/SelectListbox.js";
|
|
23
|
+
import "../../../SelectListbox/SelectProvider.js";
|
|
24
|
+
import "../../../Sortable/components/SortableItem.js";
|
|
25
|
+
import "../../../../SortableProvider-Z0e0qeQT.js";
|
|
26
|
+
export {
|
|
27
|
+
y as TablePlugin
|
|
28
|
+
};
|
|
29
|
+
//# sourceMappingURL=TablePlugin.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TablePlugin.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './TablePlugin';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|