@tiptap/core 2.7.2 → 2.7.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +7 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +7 -0
- package/dist/index.js.map +1 -1
- package/dist/index.umd.js +7 -0
- package/dist/index.umd.js.map +1 -1
- package/dist/packages/core/src/ExtensionManager.d.ts +2 -1
- package/dist/packages/core/src/types.d.ts +4 -7
- package/package.json +2 -2
- package/src/Editor.ts +7 -0
- package/src/ExtensionManager.ts +1 -1
- package/src/helpers/getRenderedAttributes.ts +3 -0
- package/src/types.ts +24 -16
package/dist/index.umd.js
CHANGED
|
@@ -340,6 +340,7 @@
|
|
|
340
340
|
|
|
341
341
|
function getRenderedAttributes(nodeOrMark, extensionAttributes) {
|
|
342
342
|
return extensionAttributes
|
|
343
|
+
.filter(attribute => attribute.type === nodeOrMark.type.name)
|
|
343
344
|
.filter(item => item.attribute.rendered)
|
|
344
345
|
.map(item => {
|
|
345
346
|
if (!item.attribute.renderHTML) {
|
|
@@ -4429,6 +4430,12 @@ img.ProseMirror-separator {
|
|
|
4429
4430
|
destroy() {
|
|
4430
4431
|
this.emit('destroy');
|
|
4431
4432
|
if (this.view) {
|
|
4433
|
+
// Cleanup our reference to prevent circular references which caused memory leaks
|
|
4434
|
+
// @ts-ignore
|
|
4435
|
+
const dom = this.view.dom;
|
|
4436
|
+
if (dom && dom.editor) {
|
|
4437
|
+
delete dom.editor;
|
|
4438
|
+
}
|
|
4432
4439
|
this.view.destroy();
|
|
4433
4440
|
}
|
|
4434
4441
|
this.removeAllListeners();
|