@ctzhian/tiptap 1.8.0 → 1.8.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Editor/demo.js +1 -1
- package/dist/type/index.d.ts +2 -2
- package/package.json +1 -1
package/dist/Editor/demo.js
CHANGED
|
@@ -9,7 +9,7 @@ import "../index.css";
|
|
|
9
9
|
var Reader = function Reader() {
|
|
10
10
|
var _useTiptap = useTiptap({
|
|
11
11
|
editable: true,
|
|
12
|
-
|
|
12
|
+
contentType: 'markdown',
|
|
13
13
|
exclude: ['invisibleCharacters'],
|
|
14
14
|
onSave: function onSave(editor) {
|
|
15
15
|
console.log('============= markdown =============');
|
package/dist/type/index.d.ts
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
import { PopoverOrigin, SxProps, Theme } from '@mui/material';
|
|
3
3
|
import { Editor, Extension } from '@tiptap/core';
|
|
4
4
|
import { YoutubeOptions } from '@tiptap/extension-youtube';
|
|
5
|
+
import { UseEditorOptions } from '@tiptap/react';
|
|
5
6
|
export type { Editor } from '@tiptap/react';
|
|
6
7
|
export interface MenuItem {
|
|
7
8
|
label?: React.ReactNode;
|
|
@@ -84,14 +85,13 @@ export type MentionExtensionProps = {
|
|
|
84
85
|
query: string;
|
|
85
86
|
}) => Promise<MentionItems>;
|
|
86
87
|
};
|
|
87
|
-
export type ModeType = 'rich-text' | 'markdown' | 'diff';
|
|
88
88
|
export type ExtensionRelativeProps = MentionExtensionProps & EditorFnProps & {
|
|
89
|
-
contentType?: ModeType;
|
|
90
89
|
limit?: number | null;
|
|
91
90
|
exclude?: string[];
|
|
92
91
|
extensions?: Extension[];
|
|
93
92
|
editable: boolean;
|
|
94
93
|
youtube?: Partial<YoutubeOptions>;
|
|
94
|
+
contentType?: UseEditorOptions['contentType'];
|
|
95
95
|
};
|
|
96
96
|
export type UseTiptapProps = {
|
|
97
97
|
onSave?: (editor: Editor) => void;
|