@fileverse-dev/ddoc 1.2.2 → 1.2.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. package/README.md +21 -22
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -28,16 +28,16 @@ The `DdocProps` interface is a TypeScript interface that defines the properties
28
28
 
29
29
  ## Properties
30
30
 
31
- | Property | Type | Description |
32
- |--------------------|---------------------------|------------------------------------------------------------|
33
- | `isPreviewMode` | `boolean` | Indicates whether the page is in preview mode or not. |
34
- | `togglePreviewMode`| `(flag: boolean) => void` | Function to toggle preview mode with a boolean flag. |
35
- | `onPublish` | `(data: Data) => void` | Function to handle publishing of the page. |
36
- | `data` (optional) | `Data` | Optional property holding data related to the page. |
37
- | `enableCollaboration` (optional) | `boolean` | Optional property to enable collaboration
38
- | `collaborationId` (optional) | `string` | When using enableCollaboration, you need to provide collaborationId, it can be uuid of doc |
39
- | `toggleCollaboration` (optional) | `(flag: boolean) => void` | Function to toggle collaboration mode with a boolean flag |
40
- | `onAutoSave` (optional) | `(flag:boolean) => void` | Function which expose the current editor state every 10 seconds |
31
+ | Property | Type | Description |
32
+ | ---------------------------------------------- | ------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- |
33
+ | `isPreviewMode` | `boolean` | Indicates whether the page is in preview mode or not. |
34
+ | `data` (optional) | `Data` | Optional property holding data related to the page. |
35
+ | `enableCollaboration` (optional) | `boolean` | Optional property to enable collaboration |
36
+ | `collaborationId` (optional) | `string` | When using enableCollaboration, you need to provide collaborationId, it can be uuid of doc |
37
+ | `toggleCollaboration` (optional) | `(flag: boolean) => void` | Function to toggle collaboration mode with a boolean flag |
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 |
40
+ | `username` (required when using collaboration) | `boolean` | Takes a username which can be used by collaboration cursor |
41
41
 
42
42
  ## Data Interface
43
43
 
@@ -45,10 +45,10 @@ The `Data` interface defines the structure of the data object that can be passed
45
45
 
46
46
  ### Properties
47
47
 
48
- | Property | Type | Description |
49
- |-------------------|------------------|------------------------------------------------|
50
- | `metaData` | `PluginMetaData` | Contains metadata related to the plugin. |
51
- | `editorJSONData` | `JSONContent` | Contains JSON data for the editor content. |
48
+ | Property | Type | Description |
49
+ | ---------------- | ---------------- | ------------------------------------------ |
50
+ | `metaData` | `PluginMetaData` | Contains metadata related to the plugin. |
51
+ | `editorJSONData` | `JSONContent` | Contains JSON data for the editor content. |
52
52
 
53
53
  ## PluginMetaData Interface
54
54
 
@@ -56,9 +56,9 @@ The `PluginMetaData` interface defines the structure of the metadata related to
56
56
 
57
57
  ### Properties
58
58
 
59
- | Property | Type | Description |
60
- |-------------------|-------------|-------------------------------------------------- |
61
- | `plugin` | `Plugin` | Contains information about the plugin title. |
59
+ | Property | Type | Description |
60
+ | -------- | -------- | -------------------------------------------- |
61
+ | `plugin` | `Plugin` | Contains information about the plugin title. |
62
62
 
63
63
  ## Plugin Interface
64
64
 
@@ -66,14 +66,13 @@ The `Plugin` interface defines the structure of the plugin information.
66
66
 
67
67
  ### Properties
68
68
 
69
- | Property | Type | Description |
70
- |------------|------------------|-------------------------------------------------------|
71
- | `title` | `string \| null` | Title of the plugin (can be `null`). |
72
-
69
+ | Property | Type | Description |
70
+ | -------- | ---------------- | ------------------------------------ |
71
+ | `title` | `string \| null` | Title of the plugin (can be `null`). |
73
72
 
74
73
  ### Steps to run this example locally
75
74
 
76
75
  - `npm i`
77
76
  - `npm run dev`
78
77
 
79
- It will open up a vite server, that will have the Ddoc Editor
78
+ It will open up a vite server, that will have the Ddoc Editor
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.2.2",
5
+ "version": "1.2.4",
6
6
  "main": "dist/index.umd.js",
7
7
  "module": "dist/index.es.js",
8
8
  "exports": {