1 import {HeadingNode, QuoteNode} from '@lexical/rich-text';
2 import {CalloutNode} from './callout';
3 import {ElementNode, KlassConstructor, LexicalNode, LexicalNodeReplacement, ParagraphNode} from "lexical";
4 import {CustomParagraphNode} from "./custom-paragraph";
5 import {LinkNode} from "@lexical/link";
8 * Load the nodes for lexical.
10 export function getNodesForPageEditor(): (KlassConstructor<typeof LexicalNode> | LexicalNodeReplacement)[] {
12 CalloutNode, // Todo - Create custom
13 HeadingNode, // Todo - Create custom
14 QuoteNode, // Todo - Create custom
17 replace: ParagraphNode,
18 with: (node: ParagraphNode) => {
19 return new CustomParagraphNode();
26 export type LexicalNodeMatcher = (node: LexicalNode|null|undefined) => boolean;
27 export type LexicalElementNodeCreator = () => ElementNode;