@fileverse-dev/ddoc 1.3.0 → 1.3.2

Sign up to get free protection for your applications and to get access to all the features.
package/README.md CHANGED
@@ -36,40 +36,21 @@ The `DdocProps` interface is a TypeScript interface that defines the properties
36
36
  | `collaborationId` (optional) | `string` | When using enableCollaboration, you need to provide collaborationId, it can be uuid of doc |
37
37
  | `toggleCollaboration` (optional) | `(flag: boolean) => void` | Function to toggle collaboration mode with a boolean flag |
38
38
  | `onAutoSave` (optional) | `(flag:boolean) => void` | Function which expose the current editor state every 10 seconds |
39
- | `renderToolRightSection` (optional) | `({editor, pluginMetaData}) => JSX.Element` | Function that render the right section of the toolbar. it calls the function with the editor instance and the pluginMedata |
39
+ | `renderToolRightSection` (optional) | `({editor}) => JSX.Element` | Function that render the right section of the toolbar. it calls the function with the editor instance |
40
+ | `renderToolLeftSection` (optional) | `({editor}) => JSX.Element` | Accept a react component
40
41
  | `username` (required when using collaboration) | `boolean` | Takes a username which can be used by collaboration cursor
41
42
  | `ensProviderUrl` | `string` | Takes a url |
42
43
 
43
44
  ## Data Interface
44
45
 
45
- The `Data` interface defines the structure of the data object that can be passed to the `onPublish` function and optionally included in the `data` property of `DdocProps`.
46
+ The `Data` interface defines the structure of the data object that can be passed to the `onAutoSave` function and optionally included in the `data` property of `DdocProps`.
46
47
 
47
48
  ### Properties
48
49
 
49
50
  | Property | Type | Description |
50
51
  | ---------------- | ---------------- | ------------------------------------------ |
51
- | `metaData` | `PluginMetaData` | Contains metadata related to the plugin. |
52
52
  | `editorJSONData` | `JSONContent` | Contains JSON data for the editor content. |
53
53
 
54
- ## PluginMetaData Interface
55
-
56
- The `PluginMetaData` interface defines the structure of the metadata related to the plugin.
57
-
58
- ### Properties
59
-
60
- | Property | Type | Description |
61
- | -------- | -------- | -------------------------------------------- |
62
- | `plugin` | `Plugin` | Contains information about the plugin title. |
63
-
64
- ## Plugin Interface
65
-
66
- The `Plugin` interface defines the structure of the plugin information.
67
-
68
- ### Properties
69
-
70
- | Property | Type | Description |
71
- | -------- | ---------------- | ------------------------------------ |
72
- | `title` | `string \| null` | Title of the plugin (can be `null`). |
73
54
 
74
55
  ### Steps to run this example locally
75
56