@fileverse-dev/ddoc 1.7.8 → 1.7.9-patch
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/index.es.js +6769 -6717
- package/dist/index.umd.js +66 -66
- package/dist/packages/ddoc/types.d.ts +3 -0
- package/dist/packages/ddoc/use-ddoc-editor.d.ts +1 -1
- package/package.json +2 -1
@@ -1,6 +1,7 @@
|
|
1
1
|
import { JSONContent } from '@tiptap/core';
|
2
2
|
import { EditorProps } from '@tiptap/pm/view';
|
3
3
|
import { Editor } from '@tiptap/react';
|
4
|
+
import { default as React, SetStateAction } from 'react';
|
4
5
|
|
5
6
|
export declare const DdocEditorProps: EditorProps;
|
6
7
|
export interface IDocCollabUsers {
|
@@ -30,6 +31,8 @@ export interface DdocProps {
|
|
30
31
|
showCommentButton?: boolean;
|
31
32
|
disableBottomToolbar?: boolean;
|
32
33
|
onError?: (error: string) => void;
|
34
|
+
setCharacterCount?: React.Dispatch<SetStateAction<number>>;
|
35
|
+
setWordCount?: React.Dispatch<SetStateAction<number>>;
|
33
36
|
}
|
34
37
|
export interface IEditorSelectionData {
|
35
38
|
from: number;
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { DdocProps } from './types';
|
2
2
|
|
3
3
|
import * as Y from 'yjs';
|
4
|
-
export declare const useDdocEditor: ({ isPreviewMode, initialContent, enableCollaboration, collaborationId, walletAddress, username, onChange, onCollaboratorChange, onCommentInteraction, onTextSelection, ensResolutionUrl, onError, }: Partial<DdocProps>) => {
|
4
|
+
export declare const useDdocEditor: ({ isPreviewMode, initialContent, enableCollaboration, collaborationId, walletAddress, username, onChange, onCollaboratorChange, onCommentInteraction, onTextSelection, ensResolutionUrl, onError, setCharacterCount, setWordCount, }: Partial<DdocProps>) => {
|
5
5
|
editor: import('@tiptap/react').Editor | null;
|
6
6
|
ref: import('react').RefObject<HTMLDivElement>;
|
7
7
|
connect: (username: string | null | undefined, isEns?: boolean) => () => void;
|
package/package.json
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
"name": "@fileverse-dev/ddoc",
|
3
3
|
"private": false,
|
4
4
|
"description": "DDoc",
|
5
|
-
"version": "1.7.
|
5
|
+
"version": "1.7.9-patch",
|
6
6
|
"main": "dist/index.umd.js",
|
7
7
|
"module": "dist/index.es.js",
|
8
8
|
"exports": {
|
@@ -33,6 +33,7 @@
|
|
33
33
|
"@tippyjs/react": "^4.2.6",
|
34
34
|
"@tiptap/core": "^2.5.4",
|
35
35
|
"@tiptap/extension-bullet-list": "^2.5.4",
|
36
|
+
"@tiptap/extension-character-count": "^2.5.6",
|
36
37
|
"@tiptap/extension-collaboration": "^2.5.4",
|
37
38
|
"@tiptap/extension-collaboration-cursor": "^2.5.4",
|
38
39
|
"@tiptap/extension-color": "^2.5.4",
|