@fileverse-dev/ddoc 1.2.3 → 1.2.5
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +21 -23
- package/dist/index.es.js +2742 -2806
- package/dist/index.umd.js +86 -101
- package/dist/packages/ddoc/ddoc-editor.d.ts +1 -1
- package/dist/packages/ddoc/types.d.ts +5 -2
- package/package.json +1 -1
@@ -1,4 +1,4 @@
|
|
1
1
|
import { DdocProps } from './types';
|
2
2
|
|
3
|
-
declare const DdocEditor: ({ isPreviewMode,
|
3
|
+
declare const DdocEditor: ({ isPreviewMode, data, enableCollaboration, collaborationId, username, onAutoSave, renderToolRightSection }: DdocProps) => import("react/jsx-runtime").JSX.Element;
|
4
4
|
export default DdocEditor;
|
@@ -1,17 +1,20 @@
|
|
1
1
|
import { JSONContent } from '@tiptap/core';
|
2
2
|
import { EditorProps } from '@tiptap/pm/view';
|
3
|
+
import { Editor } from '@tiptap/react';
|
3
4
|
|
4
5
|
export declare const DdocEditorProps: EditorProps;
|
5
6
|
export interface DdocProps {
|
6
7
|
enableCollaboration?: boolean;
|
7
8
|
collaborationId?: string;
|
8
9
|
isPreviewMode: boolean;
|
9
|
-
togglePreviewMode: (flag: boolean) => void;
|
10
10
|
toggleCollaboration?: (flag: boolean) => void;
|
11
|
-
onPublish: (data: Data) => void;
|
12
11
|
data?: Data | null;
|
13
12
|
onAutoSave?: (data: Data) => void;
|
14
13
|
username?: string;
|
14
|
+
renderToolRightSection?: ({ editor, pluginMetaData }: {
|
15
|
+
editor: Editor;
|
16
|
+
pluginMetaData: PluginMetaData;
|
17
|
+
}) => JSX.Element;
|
15
18
|
}
|
16
19
|
export interface Data {
|
17
20
|
metaData: PluginMetaData;
|