@tiptap/core
Advanced tools
Comparing version 2.0.0-alpha.7 to 2.0.0-alpha.8
@@ -6,2 +6,10 @@ # Change Log | ||
# [2.0.0-alpha.8](https://github.com/ueberdosis/tiptap-next/compare/@tiptap/core@2.0.0-alpha.7...@tiptap/core@2.0.0-alpha.8) (2020-12-18) | ||
**Note:** Version bump only for package @tiptap/core | ||
# [2.0.0-alpha.7](https://github.com/ueberdosis/tiptap-next/compare/@tiptap/core@2.0.0-alpha.6...@tiptap/core@2.0.0-alpha.7) (2020-12-02) | ||
@@ -8,0 +16,0 @@ |
@@ -106,2 +106,6 @@ import { EditorState, Plugin } from 'prosemirror-state'; | ||
/** | ||
* Creates all node views. | ||
*/ | ||
createNodeViews(): void; | ||
/** | ||
* Creates a ProseMirror document. | ||
@@ -108,0 +112,0 @@ */ |
@@ -19,3 +19,3 @@ import { Plugin, Transaction } from 'prosemirror-state'; | ||
options: Options; | ||
}) => GlobalAttributes; | ||
}) => GlobalAttributes | {}; | ||
/** | ||
@@ -22,0 +22,0 @@ * Commands |
@@ -54,3 +54,3 @@ import { DOMOutputSpec, MarkSpec, Mark as ProseMirrorMark, MarkType } from 'prosemirror-model'; | ||
options: Options; | ||
}) => Attributes; | ||
}) => Attributes | {}; | ||
/** | ||
@@ -57,0 +57,0 @@ * Commands |
@@ -94,3 +94,3 @@ import { DOMOutputSpec, NodeSpec, Node as ProseMirrorNode, NodeType } from 'prosemirror-model'; | ||
options: Options; | ||
}) => Attributes; | ||
}) => Attributes | {}; | ||
/** | ||
@@ -97,0 +97,0 @@ * Commands |
@@ -90,6 +90,6 @@ import { Node as ProseMirrorNode, ParseOptions } from 'prosemirror-model'; | ||
getPos: (() => number) | boolean; | ||
decorations: Decoration[]; | ||
HTMLAttributes: { | ||
[key: string]: any; | ||
}; | ||
decorations: Decoration[]; | ||
extension: Node; | ||
@@ -96,0 +96,0 @@ }; |
{ | ||
"name": "@tiptap/core", | ||
"description": "headless rich text editor", | ||
"version": "2.0.0-alpha.7", | ||
"version": "2.0.0-alpha.8", | ||
"homepage": "https://tiptap.dev", | ||
@@ -46,3 +46,3 @@ "keywords": [ | ||
}, | ||
"gitHead": "a884cb81de8783d0097741c1ddb97a82ea88ae0e" | ||
"gitHead": "0371cb0a5d803a44d93532aa34419ec7ffffdc24" | ||
} |
@@ -255,5 +255,3 @@ import { EditorState, Plugin, Transaction } from 'prosemirror-state' | ||
this.view.setProps({ | ||
nodeViews: this.extensionManager.nodeViews, | ||
}) | ||
this.createNodeViews() | ||
@@ -267,2 +265,11 @@ // Let’s store the editor instance in the DOM element. | ||
/** | ||
* Creates all node views. | ||
*/ | ||
public createNodeViews() { | ||
this.view.setProps({ | ||
nodeViews: this.extensionManager.nodeViews, | ||
}) | ||
} | ||
/** | ||
* Creates a ProseMirror document. | ||
@@ -385,3 +392,6 @@ */ | ||
public isEmpty() { | ||
return !this.state.doc.textContent.length | ||
const defaultContent = this.state.doc.type.createAndFill()?.toJSON() | ||
const content = this.getJSON() | ||
return JSON.stringify(defaultContent) === JSON.stringify(content) | ||
} | ||
@@ -388,0 +398,0 @@ |
@@ -22,3 +22,3 @@ import { Plugin, Transaction } from 'prosemirror-state' | ||
options: Options, | ||
}) => GlobalAttributes, | ||
}) => GlobalAttributes | {}, | ||
@@ -25,0 +25,0 @@ /** |
@@ -63,3 +63,3 @@ import { | ||
}, | ||
) => Attributes, | ||
) => Attributes | {}, | ||
@@ -66,0 +66,0 @@ /** |
@@ -98,3 +98,3 @@ import { | ||
}, | ||
) => Attributes, | ||
) => Attributes | {}, | ||
@@ -101,0 +101,0 @@ /** |
@@ -95,4 +95,4 @@ import { Node as ProseMirrorNode, ParseOptions } from 'prosemirror-model' | ||
getPos: (() => number) | boolean, | ||
HTMLAttributes: { [key: string]: any }, | ||
decorations: Decoration[], | ||
HTMLAttributes: { [key: string]: any }, | ||
extension: Node, | ||
@@ -99,0 +99,0 @@ } |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
12077
2022326