Classes
AbstractEditorAnnotationCommandCommandComponentConfiguratorContainerSelectionDOMImporterDocumentDocumentNodeEditAnnotationCommandEditingEventEmitterInsertInlineNodeCommandNodeIndexPropertyAnnotationPropertySelectionProseEditorScrollPaneSelectionSpellCheckCommandSurfaceTextNodeTransactionDocumentVirtualElement
Components
Modules
IncrementalData
Class defined in model/data/IncrementalData.js#15 inherits from
Incremental data storage implemention.
this.create(nodeData)
Method defined in model/data/IncrementalData.js#23
Create a new node.
Parameters
nodeData | object |
Returns
ObjectOperation | The applied operation. |
this.delete(nodeId)
Method defined in model/data/IncrementalData.js#38
Delete a node.
Parameters
nodeId | String |
Returns
ObjectOperation | The applied operation. |
this.update(path, diff)
Method defined in model/data/IncrementalData.js#64
Update a property incrementally.
The diff can be of the following forms (depending on the updated property type):
- String:
{ insert: { offset: Number, value: Object } }
{ delete: { start: Number, end: Number } }
- Array:
{ insert: { offset: Number, value: Object } }
{ delete: { offset: Number } }
Parameters
path | array | |
diff | object |
Returns
ObjectOperation | The applied operation. |
this.set(path, newValue)
Method defined in model/data/IncrementalData.js#78
Set a property to a new value
Parameters
path | Array | |
newValue | Object |
Returns
ObjectOperation | The applied operation. |
this.apply(op)
Method defined in model/data/IncrementalData.js#90
Apply a given operation.
Parameters
op | ObjectOperation |
this._getDiffOp(path, diff)
Method defined in model/data/IncrementalData.js#136
Creates proper operation based on provided node path and diff.
Parameters
path | Array | |
diff | Object |
Returns
ObjectOperation | operation. |