Implement markdown parsing for copy paste
Signed-off-by: Émile Ré <emile@getprobo.com>
This commit is contained in:
14
packages/ui/src/RichEditor/CodeBlockExtension.ts
Normal file
14
packages/ui/src/RichEditor/CodeBlockExtension.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
// Copyright (c) 2026 Probo Inc <hello@getprobo.com>.
|
||||
// Use of this source code is governed by the ISC license
|
||||
// that can be found in the LICENSE file.
|
||||
|
||||
import { CodeBlock } from "@tiptap/extension-code-block";
|
||||
import { ReactNodeViewRenderer } from "@tiptap/react";
|
||||
|
||||
import { MermaidNodeView } from "./MermaidNodeView";
|
||||
|
||||
export const CodeBlockExtension = CodeBlock.extend({
|
||||
addNodeView() {
|
||||
return ReactNodeViewRenderer(MermaidNodeView);
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user