mirror of
https://github.com/rzmk/learnhouse.git
synced 2025-12-19 04:19:25 +00:00
feat: add WebPreviews blocks
This commit is contained in:
parent
b1c4ddd0b7
commit
8d3ede1486
11 changed files with 482 additions and 0 deletions
|
|
@ -34,6 +34,7 @@ import Link from 'next/link'
|
|||
import { getCourseThumbnailMediaDirectory } from '@services/media/media'
|
||||
import { getLinkExtension } from './EditorConf'
|
||||
import { Link as LinkExtension } from '@tiptap/extension-link'
|
||||
import WebPreview from './Extensions/WebPreview/WebPreview'
|
||||
|
||||
// Lowlight
|
||||
import { common, createLowlight } from 'lowlight'
|
||||
|
|
@ -164,6 +165,10 @@ function Editor(props: Editor) {
|
|||
TableHeader,
|
||||
TableCell,
|
||||
getLinkExtension(),
|
||||
WebPreview.configure({
|
||||
editable: true,
|
||||
activity: props.activity,
|
||||
}),
|
||||
],
|
||||
content: props.content,
|
||||
immediatelyRender: false,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue