From b71df1e46f06463795151362eba44cd3421c7d0e Mon Sep 17 00:00:00 2001 From: Oliver Walters Date: Sat, 24 Aug 2024 04:49:54 +0000 Subject: [PATCH] Support for thematic breaks - Use the '-' character --- .../src/components/editors/NotesEditor.tsx | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/src/frontend/src/components/editors/NotesEditor.tsx b/src/frontend/src/components/editors/NotesEditor.tsx index 30343af5fa..eefe996e3b 100644 --- a/src/frontend/src/components/editors/NotesEditor.tsx +++ b/src/frontend/src/components/editors/NotesEditor.tsx @@ -10,6 +10,7 @@ import { InsertAdmonition, InsertImage, InsertTable, + InsertThematicBreak, ListsToggle, MDXEditor, type MDXEditorMethods, @@ -24,6 +25,7 @@ import { markdownShortcutPlugin, quotePlugin, tablePlugin, + thematicBreakPlugin, toolbarPlugin } from '@mdxeditor/editor'; import '@mdxeditor/editor/style.css'; @@ -186,7 +188,8 @@ export default function NotesEditor({ listsPlugin(), markdownShortcutPlugin(), quotePlugin(), - tablePlugin() + tablePlugin(), + thematicBreakPlugin() ]; let toolbar: ReactNode[] = []; @@ -225,7 +228,8 @@ export default function NotesEditor({ , , , - + , + ]; } } @@ -255,6 +259,14 @@ export default function NotesEditor({ ]); return ( - + ); }