]> BookStack Code Mirror - bookstack/blobdiff - resources/js/wysiwyg/nodes/index.ts
Lexical: Added basic list button/support
[bookstack] / resources / js / wysiwyg / nodes / index.ts
index ffe1b027fe5d543391bb7370353b23b6efce6e92..03fcd33a5b3e6606ae36aac7be90b5e4a7994679 100644 (file)
@@ -2,6 +2,10 @@ import {HeadingNode, QuoteNode} from '@lexical/rich-text';
 import {CalloutNode} from './callout';
 import {ElementNode, KlassConstructor, LexicalNode, LexicalNodeReplacement, ParagraphNode} from "lexical";
 import {CustomParagraphNode} from "./custom-paragraph";
+import {LinkNode} from "@lexical/link";
+import {ImageNode} from "./image";
+import {DetailsNode, SummaryNode} from "./details";
+import {ListItemNode, ListNode} from "@lexical/list";
 
 /**
  * Load the nodes for lexical.
@@ -11,13 +15,18 @@ export function getNodesForPageEditor(): (KlassConstructor<typeof LexicalNode> |
         CalloutNode, // Todo - Create custom
         HeadingNode, // Todo - Create custom
         QuoteNode, // Todo - Create custom
+        ListNode, // Todo - Create custom
+        ListItemNode,
+        ImageNode,
+        DetailsNode, SummaryNode,
         CustomParagraphNode,
         {
             replace: ParagraphNode,
             with: (node: ParagraphNode) => {
                 return new CustomParagraphNode();
             }
-        }
+        },
+        LinkNode,
     ];
 }