@react-fabric/lexical 1.0.0-beta.5 → 1.0.0-beta.52
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/{src/editor/Lexical.module.css → css/_lexical.css} +4 -4
- package/css/styles.css +24 -0
- package/dist/cjs/node_modules/@lexical/clipboard/LexicalClipboard.dev.js +29 -19
- package/dist/cjs/node_modules/@lexical/clipboard/LexicalClipboard.js +1 -1
- package/dist/cjs/node_modules/@lexical/clipboard/LexicalClipboard.prod.js +9 -9
- package/dist/cjs/node_modules/@lexical/code/LexicalCode.dev.js +142 -75
- package/dist/cjs/node_modules/@lexical/code/LexicalCode.js +1 -1
- package/dist/cjs/node_modules/@lexical/code/LexicalCode.prod.js +25 -21
- package/dist/cjs/node_modules/@lexical/html/LexicalHtml.dev.js +10 -3
- package/dist/cjs/node_modules/@lexical/html/LexicalHtml.js +1 -1
- package/dist/cjs/node_modules/@lexical/html/LexicalHtml.prod.js +3 -3
- package/dist/cjs/node_modules/@lexical/link/LexicalLink.dev.js +147 -103
- package/dist/cjs/node_modules/@lexical/link/LexicalLink.js +1 -1
- package/dist/cjs/node_modules/@lexical/link/LexicalLink.prod.js +10 -10
- package/dist/cjs/node_modules/@lexical/list/LexicalList.dev.js +254 -178
- package/dist/cjs/node_modules/@lexical/list/LexicalList.js +1 -1
- package/dist/cjs/node_modules/@lexical/list/LexicalList.prod.js +19 -16
- package/dist/cjs/node_modules/@lexical/rich-text/LexicalRichText.dev.js +53 -29
- package/dist/cjs/node_modules/@lexical/rich-text/LexicalRichText.js +1 -1
- package/dist/cjs/node_modules/@lexical/rich-text/LexicalRichText.prod.js +10 -10
- package/dist/cjs/node_modules/@lexical/selection/LexicalSelection.dev.js +176 -194
- package/dist/cjs/node_modules/@lexical/selection/LexicalSelection.js +1 -1
- package/dist/cjs/node_modules/@lexical/selection/LexicalSelection.prod.js +25 -18
- package/dist/cjs/node_modules/@lexical/table/LexicalTable.dev.js +1925 -793
- package/dist/cjs/node_modules/@lexical/table/LexicalTable.js +1 -1
- package/dist/cjs/node_modules/@lexical/table/LexicalTable.prod.js +48 -40
- package/dist/cjs/node_modules/@lexical/utils/LexicalUtils.dev.js +426 -144
- package/dist/cjs/node_modules/@lexical/utils/LexicalUtils.js +11 -1
- package/dist/cjs/node_modules/@lexical/utils/LexicalUtils.prod.js +46 -32
- package/dist/cjs/node_modules/prismjs/prism.js +1 -1
- package/dist/cjs/packages/lexical/src/components/StickyComponent.js +1 -1
- package/dist/cjs/packages/lexical/src/editor/LexicalEditor.js +29 -5
- package/dist/cjs/packages/lexical/src/hooks/useFormatWatcher.js +81 -76
- package/dist/cjs/packages/lexical/src/plugins/ToolbarPlugin.js +4 -6
- package/dist/esm/node_modules/@lexical/clipboard/LexicalClipboard.dev.js +29 -19
- package/dist/esm/node_modules/@lexical/clipboard/LexicalClipboard.js +1 -1
- package/dist/esm/node_modules/@lexical/clipboard/LexicalClipboard.prod.js +3 -3
- package/dist/esm/node_modules/@lexical/code/LexicalCode.dev.js +139 -76
- package/dist/esm/node_modules/@lexical/code/LexicalCode.js +1 -1
- package/dist/esm/node_modules/@lexical/code/LexicalCode.prod.js +4 -4
- package/dist/esm/node_modules/@lexical/html/LexicalHtml.dev.js +11 -4
- package/dist/esm/node_modules/@lexical/html/LexicalHtml.js +1 -1
- package/dist/esm/node_modules/@lexical/html/LexicalHtml.prod.js +3 -3
- package/dist/esm/node_modules/@lexical/link/LexicalLink.dev.js +149 -105
- package/dist/esm/node_modules/@lexical/link/LexicalLink.js +1 -1
- package/dist/esm/node_modules/@lexical/link/LexicalLink.prod.js +4 -4
- package/dist/esm/node_modules/@lexical/list/LexicalList.dev.js +253 -180
- package/dist/esm/node_modules/@lexical/list/LexicalList.js +1 -1
- package/dist/esm/node_modules/@lexical/list/LexicalList.prod.js +4 -4
- package/dist/esm/node_modules/@lexical/rich-text/LexicalRichText.dev.js +54 -30
- package/dist/esm/node_modules/@lexical/rich-text/LexicalRichText.js +1 -1
- package/dist/esm/node_modules/@lexical/rich-text/LexicalRichText.prod.js +3 -3
- package/dist/esm/node_modules/@lexical/selection/LexicalSelection.dev.js +171 -196
- package/dist/esm/node_modules/@lexical/selection/LexicalSelection.js +1 -1
- package/dist/esm/node_modules/@lexical/selection/LexicalSelection.prod.js +4 -4
- package/dist/esm/node_modules/@lexical/table/LexicalTable.dev.js +1920 -796
- package/dist/esm/node_modules/@lexical/table/LexicalTable.js +1 -1
- package/dist/esm/node_modules/@lexical/table/LexicalTable.prod.js +4 -4
- package/dist/esm/node_modules/@lexical/utils/LexicalUtils.dev.js +413 -145
- package/dist/esm/node_modules/@lexical/utils/LexicalUtils.js +7 -2
- package/dist/esm/node_modules/@lexical/utils/LexicalUtils.prod.js +3 -3
- package/dist/esm/node_modules/prismjs/prism.js +1 -1
- package/dist/esm/packages/lexical/src/components/StickyComponent.js +1 -1
- package/dist/esm/packages/lexical/src/editor/LexicalEditor.js +29 -5
- package/dist/esm/packages/lexical/src/hooks/useFormatWatcher.js +82 -77
- package/dist/esm/packages/lexical/src/plugins/ToolbarPlugin.js +4 -6
- package/dist/types/editor/LexicalEditor.d.ts +25 -0
- package/dist/types/hooks/useFormatWatcher.d.ts +2 -2
- package/dist/types/nodes/StickyNode.d.ts +0 -1
- package/package.json +13 -12
- package/src/components/StickyComponent.tsx +2 -2
- package/src/editor/LexicalEditor.tsx +53 -25
- package/src/hooks/useFormatWatcher.ts +28 -27
- package/src/plugins/ToolbarPlugin.tsx +22 -6
- package/dist/cjs/editor/Lexical.module.css +0 -1
- package/dist/esm/editor/Lexical.module.css +0 -1
|
@@ -25,7 +25,10 @@ import { CodeHighlightNode, CodeNode } from "@lexical/code";
|
|
|
25
25
|
import { ListItemNode, ListNode } from "@lexical/list";
|
|
26
26
|
import { AutoFocusPlugin } from "@lexical/react/LexicalAutoFocusPlugin";
|
|
27
27
|
import { CheckListPlugin } from "@lexical/react/LexicalCheckListPlugin";
|
|
28
|
-
import {
|
|
28
|
+
import {
|
|
29
|
+
type InitialConfigType,
|
|
30
|
+
LexicalComposer,
|
|
31
|
+
} from "@lexical/react/LexicalComposer";
|
|
29
32
|
import { ContentEditable } from "@lexical/react/LexicalContentEditable";
|
|
30
33
|
import { LexicalErrorBoundary } from "@lexical/react/LexicalErrorBoundary";
|
|
31
34
|
import { HistoryPlugin } from "@lexical/react/LexicalHistoryPlugin";
|
|
@@ -42,9 +45,8 @@ import { useCallback, useEffect, useMemo, useRef, useState } from "react";
|
|
|
42
45
|
import { StickyNode } from "../nodes/StickyNode";
|
|
43
46
|
import { DraggableBlockPlugin } from "../plugins/DraggableBlockPlugin";
|
|
44
47
|
import { StickyPlugin } from "../plugins/StickyPlugin";
|
|
45
|
-
import classes from "./Lexical.module.css";
|
|
46
|
-
import { LexicalTheme } from "./theme";
|
|
47
48
|
import { ToolbarPlugin } from "../plugins/ToolbarPlugin";
|
|
49
|
+
import { LexicalTheme } from "./theme";
|
|
48
50
|
|
|
49
51
|
export interface EditorProps {
|
|
50
52
|
value?: string | AnyObject;
|
|
@@ -62,6 +64,31 @@ export interface EditorProps {
|
|
|
62
64
|
onDirty?: (isDirty: boolean) => void;
|
|
63
65
|
}
|
|
64
66
|
|
|
67
|
+
/**
|
|
68
|
+
* LexicalEditor component is a rich text editor built using Lexical.
|
|
69
|
+
* It supports various features such as code highlighting, lists, tables, and sticky notes.
|
|
70
|
+
* It provides a customizable toolbar and handles editor state changes.
|
|
71
|
+
* It also supports drag-and-drop functionality for blocks.
|
|
72
|
+
* It can be used in both read-only and editable modes, and supports publishing mode for exporting content.
|
|
73
|
+
* It uses a custom theme and provides error handling for Lexical updates.
|
|
74
|
+
*
|
|
75
|
+
* @param {EditorProps} props - The properties for the LexicalEditor component.
|
|
76
|
+
* @returns {JSX.Element} The rendered LexicalEditor component.
|
|
77
|
+
*
|
|
78
|
+
* @example
|
|
79
|
+
* ```jsx
|
|
80
|
+
* <LexicalEditor
|
|
81
|
+
* value={initialValue}
|
|
82
|
+
* readOnly={false}
|
|
83
|
+
* publishMode={false}
|
|
84
|
+
* onChange={(value) => console.log("Editor value changed:", value)}
|
|
85
|
+
* onDirty={(isDirty) => console.log("Editor is dirty:", isDirty)}
|
|
86
|
+
* />
|
|
87
|
+
* ```
|
|
88
|
+
*
|
|
89
|
+
* @see {@link https://adarshpastakia.github.io/react-fabric/?path=/story/lexical-playground--playground}
|
|
90
|
+
* @see {@link https://lexical.dev/docs/}
|
|
91
|
+
*/
|
|
65
92
|
export const LexicalEditor = ({
|
|
66
93
|
value,
|
|
67
94
|
readOnly,
|
|
@@ -69,7 +96,7 @@ export const LexicalEditor = ({
|
|
|
69
96
|
onChange,
|
|
70
97
|
onDirty,
|
|
71
98
|
}: EditorProps) => {
|
|
72
|
-
const editorRef = useRef<LXE>();
|
|
99
|
+
const editorRef = useRef<LXE>(null);
|
|
73
100
|
const [editorContainer, setEditorContainer] = useState<HTMLDivElement | null>(
|
|
74
101
|
null,
|
|
75
102
|
);
|
|
@@ -135,25 +162,26 @@ export const LexicalEditor = ({
|
|
|
135
162
|
}, [readOnly, publishMode]);
|
|
136
163
|
|
|
137
164
|
const initialConfig = useMemo(
|
|
138
|
-
() =>
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
165
|
+
() =>
|
|
166
|
+
({
|
|
167
|
+
editorState: initEditor,
|
|
168
|
+
namespace: "MyEditor",
|
|
169
|
+
editable: !readOnly && !publishMode,
|
|
170
|
+
theme: LexicalTheme,
|
|
171
|
+
nodes: [
|
|
172
|
+
QuoteNode,
|
|
173
|
+
HeadingNode,
|
|
174
|
+
CodeHighlightNode,
|
|
175
|
+
CodeNode,
|
|
176
|
+
ListItemNode,
|
|
177
|
+
ListNode,
|
|
178
|
+
TableCellNode,
|
|
179
|
+
TableNode,
|
|
180
|
+
TableRowNode,
|
|
181
|
+
StickyNode,
|
|
182
|
+
],
|
|
183
|
+
onError,
|
|
184
|
+
}) as InitialConfigType,
|
|
157
185
|
[],
|
|
158
186
|
);
|
|
159
187
|
|
|
@@ -162,7 +190,7 @@ export const LexicalEditor = ({
|
|
|
162
190
|
return !publishMode ? (
|
|
163
191
|
<div className="lexical-scroller area-content overflow-auto">
|
|
164
192
|
<div
|
|
165
|
-
className={classNames(
|
|
193
|
+
className={classNames("fabric-lexicalToolbar", "sticky top-0 z-1")}
|
|
166
194
|
>
|
|
167
195
|
<Header className="bg-base">
|
|
168
196
|
<ToolbarPlugin />
|
|
@@ -185,7 +213,7 @@ export const LexicalEditor = ({
|
|
|
185
213
|
<div
|
|
186
214
|
role="none"
|
|
187
215
|
className={classNames(
|
|
188
|
-
|
|
216
|
+
"fabric-lexicalEditor",
|
|
189
217
|
"lexical-container relative bg-white min-h-full mx-auto shadow-md print:shadow-none",
|
|
190
218
|
)}
|
|
191
219
|
onDragOver={(e) => e.stopPropagation()}
|
|
@@ -53,6 +53,7 @@ import {
|
|
|
53
53
|
$getNearestNodeOfType,
|
|
54
54
|
mergeRegister,
|
|
55
55
|
} from "@lexical/utils";
|
|
56
|
+
import { isNil } from "@react-fabric/utilities";
|
|
56
57
|
import {
|
|
57
58
|
$createParagraphNode,
|
|
58
59
|
$getSelection,
|
|
@@ -62,7 +63,6 @@ import {
|
|
|
62
63
|
CAN_REDO_COMMAND,
|
|
63
64
|
CAN_UNDO_COMMAND,
|
|
64
65
|
COMMAND_PRIORITY_CRITICAL,
|
|
65
|
-
FOCUS_COMMAND,
|
|
66
66
|
INDENT_CONTENT_COMMAND,
|
|
67
67
|
OUTDENT_CONTENT_COMMAND,
|
|
68
68
|
SELECTION_CHANGE_COMMAND,
|
|
@@ -114,6 +114,7 @@ export const useFormatWatcher = () => {
|
|
|
114
114
|
const [, startTransition] = useTransition();
|
|
115
115
|
const [editor] = useLexicalComposerContext();
|
|
116
116
|
const [activeEditor, setActiveEditor] = useState(editor);
|
|
117
|
+
const [currentSelection, setCurrentSelection] = useState<AnyObject>();
|
|
117
118
|
const [blockType, setBlockType] =
|
|
118
119
|
useState<keyof typeof blockTypeToBlockName>("paragraph");
|
|
119
120
|
const [rootType, setRootType] =
|
|
@@ -218,41 +219,46 @@ export const useFormatWatcher = () => {
|
|
|
218
219
|
) + "",
|
|
219
220
|
);
|
|
220
221
|
setFontColor(
|
|
221
|
-
$getSelectionStyleValueForProperty(
|
|
222
|
+
$getSelectionStyleValueForProperty(
|
|
223
|
+
selection,
|
|
224
|
+
"color",
|
|
225
|
+
// @ts-expect-error ignore
|
|
226
|
+
// eslint-disable-next-line no-new-wrappers
|
|
227
|
+
new String("#000"),
|
|
228
|
+
),
|
|
222
229
|
);
|
|
223
230
|
setBgColor(
|
|
224
231
|
$getSelectionStyleValueForProperty(
|
|
225
232
|
selection,
|
|
226
233
|
"background-color",
|
|
227
|
-
|
|
234
|
+
// @ts-expect-error ignore
|
|
235
|
+
// eslint-disable-next-line no-new-wrappers
|
|
236
|
+
new String("#fff"),
|
|
228
237
|
),
|
|
229
238
|
);
|
|
230
239
|
setFontFamily(
|
|
231
240
|
$getSelectionStyleValueForProperty(selection, "font-family", "inherit"),
|
|
232
241
|
);
|
|
233
242
|
}
|
|
234
|
-
}, [
|
|
243
|
+
}, []);
|
|
235
244
|
|
|
236
245
|
useEffect(() => {
|
|
237
246
|
return editor.registerCommand(
|
|
238
|
-
|
|
247
|
+
SELECTION_CHANGE_COMMAND,
|
|
239
248
|
(_payload, newEditor) => {
|
|
240
249
|
setActiveEditor(newEditor);
|
|
250
|
+
setCurrentSelection($getSelection());
|
|
251
|
+
$updateToolbar();
|
|
241
252
|
return false;
|
|
242
253
|
},
|
|
243
254
|
COMMAND_PRIORITY_CRITICAL,
|
|
244
255
|
);
|
|
245
|
-
}, [editor]);
|
|
256
|
+
}, [editor, $updateToolbar]);
|
|
246
257
|
|
|
247
258
|
useEffect(() => {
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
$updateToolbar();
|
|
252
|
-
return false;
|
|
253
|
-
},
|
|
254
|
-
COMMAND_PRIORITY_CRITICAL,
|
|
255
|
-
);
|
|
259
|
+
activeEditor.getEditorState().read(() => {
|
|
260
|
+
$updateToolbar();
|
|
261
|
+
});
|
|
256
262
|
}, [activeEditor, $updateToolbar]);
|
|
257
263
|
|
|
258
264
|
useEffect(() => {
|
|
@@ -286,16 +292,13 @@ export const useFormatWatcher = () => {
|
|
|
286
292
|
|
|
287
293
|
const applyStyleText = useCallback(
|
|
288
294
|
(styles: Record<string, string>) => {
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
}
|
|
295
|
-
});
|
|
296
|
-
}, 100);
|
|
295
|
+
activeEditor.update(() => {
|
|
296
|
+
if (!isNil(currentSelection)) {
|
|
297
|
+
$patchStyleText(currentSelection, styles);
|
|
298
|
+
}
|
|
299
|
+
});
|
|
297
300
|
},
|
|
298
|
-
[
|
|
301
|
+
[activeEditor, currentSelection],
|
|
299
302
|
);
|
|
300
303
|
|
|
301
304
|
const formatBulletList = () => {
|
|
@@ -439,16 +442,14 @@ export const useFormatWatcher = () => {
|
|
|
439
442
|
);
|
|
440
443
|
|
|
441
444
|
const onFontColorSelect = useCallback(
|
|
442
|
-
(value: string) => {
|
|
443
|
-
startTransition(() => setFontColor(value));
|
|
445
|
+
(value: string = "#000000") => {
|
|
444
446
|
applyStyleText({ color: value });
|
|
445
447
|
},
|
|
446
448
|
[applyStyleText],
|
|
447
449
|
);
|
|
448
450
|
|
|
449
451
|
const onBgColorSelect = useCallback(
|
|
450
|
-
(value: string) => {
|
|
451
|
-
startTransition(() => setBgColor(value));
|
|
452
|
+
(value: string = "#ffffff") => {
|
|
452
453
|
applyStyleText({ "background-color": value });
|
|
453
454
|
},
|
|
454
455
|
[applyStyleText],
|
|
@@ -1,8 +1,24 @@
|
|
|
1
1
|
/*
|
|
2
|
-
*
|
|
3
|
-
* @version
|
|
4
|
-
*
|
|
5
|
-
*
|
|
2
|
+
* React Fabric
|
|
3
|
+
* @version: 1.0.0
|
|
4
|
+
*
|
|
5
|
+
*
|
|
6
|
+
* The MIT License (MIT)
|
|
7
|
+
* Copyright (c) 2025 Adarsh Pastakia
|
|
8
|
+
*
|
|
9
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software
|
|
10
|
+
* and associated documentation files (the "Software"), to deal in the Software without restriction,
|
|
11
|
+
* including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
|
12
|
+
* and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so,
|
|
13
|
+
* subject to the following conditions:
|
|
14
|
+
*
|
|
15
|
+
* The above copyright notice and this permission notice shall be included in all copies or substantial
|
|
16
|
+
* portions of the Software.
|
|
17
|
+
*
|
|
18
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
|
|
19
|
+
* TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
|
20
|
+
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
|
21
|
+
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
6
22
|
*/
|
|
7
23
|
|
|
8
24
|
import {
|
|
@@ -252,13 +268,13 @@ export const ToolbarPlugin = () => {
|
|
|
252
268
|
<ColorInput
|
|
253
269
|
{...{ noOutline: true }}
|
|
254
270
|
value={watch.fontColor}
|
|
255
|
-
onChange={(v
|
|
271
|
+
onChange={(v) => watch.onFontColorSelect(v ?? undefined)}
|
|
256
272
|
decorateStart={<Icon icon={CoreIcons.formatText} />}
|
|
257
273
|
/>
|
|
258
274
|
<ColorInput
|
|
259
275
|
{...{ noOutline: true }}
|
|
260
276
|
value={watch.bgColor}
|
|
261
|
-
onChange={(v
|
|
277
|
+
onChange={(v) => watch.onBgColorSelect(v ?? undefined)}
|
|
262
278
|
decorateStart={<Icon icon={CoreIcons.formatFill} />}
|
|
263
279
|
/>
|
|
264
280
|
<ButtonWrapper
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
@layer util{.lexicalEditor,.lexicalToolbar{margin:0 auto;width:21cm}.lexicalEditor :global{.editor-container.editor-container.editor-container{background-color:#fff;color:#0f172a;font-family:Sakkal Majalla;font-size:18px}.editor-heading-h1{font-size:1.5em;margin-bottom:1.5em;text-transform:capitalize}.editor-heading-h1,.editor-heading-h2{font-weight:600;line-height:1.5;margin-top:1.5em;padding:0 4px}.editor-heading-h2{font-size:1.25em;margin-bottom:1em}.editor-heading-h6{color:#b45309;font-size:.875em;font-weight:600;line-height:1.25;margin-bottom:1.5em;margin-top:1.5em}.editor-paragraph{font-size:1em}.editor-paragraph,.editor-quote{line-height:1.5;margin-bottom:1.5em;margin-top:1.5em}.editor-quote{border-color:#64748b;padding-inline-start:1em}.editor-code,.editor-quote{border-inline-start-width:4px;color:#1e293b;display:block;font-size:1.125em}.editor-code{background-color:#e2e8f0;line-height:1.5;margin-bottom:1.5em;margin-top:1.5em;padding:1em}.editor-textUnderline{text-decoration:underline}.editor-textStrikethrough{text-decoration:line-through}.editor-textUnderlineStrikethrough{text-decoration:underline line-through}.editor-page-break{page-break-after:always}.editor-no-break{page-break-inside:avoid}.editor-textSmall{font-size:.875em}.editor-textBold{font-weight:600}.editor-textItalic{font-style:italic}.editor-textMuted{color:#4b5563}.editor-list-ul{list-style:disc;padding-inline-start:.5em}.editor-list-ol{list-style:decimal;padding-inline-start:.5em}.editor-listItem{margin-inline-start:1em;text-align:start}@media print{body,html{margin:0;min-height:100vh}div,h1,h2,h3,h4,h5,h6,p,span{box-sizing:border-box}body.report-template{background-size:0;min-height:100vh}body:after{background-image:inherit;content:"";height:100vh;inset:0;margin:0 auto;max-width:21cm;position:fixed;-webkit-print-color-adjust:exact;print-color-adjust:exact;width:100vw;z-index:10}.editor-page-break>div,.sticky__container{display:none}.editor-container{position:relative}.editor-editor{box-sizing:border-box;padding:0 2cm}}}}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
@layer util{.lexicalEditor,.lexicalToolbar{margin:0 auto;width:21cm}.lexicalEditor :global{.editor-container.editor-container.editor-container{background-color:#fff;color:#0f172a;font-family:Sakkal Majalla;font-size:18px}.editor-heading-h1{font-size:1.5em;margin-bottom:1.5em;text-transform:capitalize}.editor-heading-h1,.editor-heading-h2{font-weight:600;line-height:1.5;margin-top:1.5em;padding:0 4px}.editor-heading-h2{font-size:1.25em;margin-bottom:1em}.editor-heading-h6{color:#b45309;font-size:.875em;font-weight:600;line-height:1.25;margin-bottom:1.5em;margin-top:1.5em}.editor-paragraph{font-size:1em}.editor-paragraph,.editor-quote{line-height:1.5;margin-bottom:1.5em;margin-top:1.5em}.editor-quote{border-color:#64748b;padding-inline-start:1em}.editor-code,.editor-quote{border-inline-start-width:4px;color:#1e293b;display:block;font-size:1.125em}.editor-code{background-color:#e2e8f0;line-height:1.5;margin-bottom:1.5em;margin-top:1.5em;padding:1em}.editor-textUnderline{text-decoration:underline}.editor-textStrikethrough{text-decoration:line-through}.editor-textUnderlineStrikethrough{text-decoration:underline line-through}.editor-page-break{page-break-after:always}.editor-no-break{page-break-inside:avoid}.editor-textSmall{font-size:.875em}.editor-textBold{font-weight:600}.editor-textItalic{font-style:italic}.editor-textMuted{color:#4b5563}.editor-list-ul{list-style:disc;padding-inline-start:.5em}.editor-list-ol{list-style:decimal;padding-inline-start:.5em}.editor-listItem{margin-inline-start:1em;text-align:start}@media print{body,html{margin:0;min-height:100vh}div,h1,h2,h3,h4,h5,h6,p,span{box-sizing:border-box}body.report-template{background-size:0;min-height:100vh}body:after{background-image:inherit;content:"";height:100vh;inset:0;margin:0 auto;max-width:21cm;position:fixed;-webkit-print-color-adjust:exact;print-color-adjust:exact;width:100vw;z-index:10}.editor-page-break>div,.sticky__container{display:none}.editor-container{position:relative}.editor-editor{box-sizing:border-box;padding:0 2cm}}}}
|