@tiptap/core 3.5.2 → 3.6.0
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 +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +9 -5
- package/dist/index.d.ts +9 -5
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
- package/src/Editor.ts +2 -2
- package/src/types.ts +6 -4
package/dist/index.d.cts
CHANGED
|
@@ -1099,11 +1099,15 @@ interface EditorEvents {
|
|
|
1099
1099
|
type EnableRules = (AnyExtension | string)[] | boolean;
|
|
1100
1100
|
interface EditorOptions {
|
|
1101
1101
|
/**
|
|
1102
|
-
* The element
|
|
1103
|
-
* If `
|
|
1104
|
-
* If
|
|
1105
|
-
|
|
1106
|
-
|
|
1102
|
+
* The element to bind the editor to:
|
|
1103
|
+
* - If an `Element` is passed, the editor will be mounted appended to that element
|
|
1104
|
+
* - If `null` is passed, the editor will not be mounted automatically
|
|
1105
|
+
* - If an object with a `mount` property is passed, the editor will be mounted to that element
|
|
1106
|
+
* - If a function is passed, it will be called with the editor's element, which should place the editor within the document
|
|
1107
|
+
*/
|
|
1108
|
+
element: Element | {
|
|
1109
|
+
mount: HTMLElement;
|
|
1110
|
+
} | ((editor: HTMLElement) => void) | null;
|
|
1107
1111
|
/**
|
|
1108
1112
|
* The content of the editor (HTML, JSON, or a JSON array)
|
|
1109
1113
|
*/
|
package/dist/index.d.ts
CHANGED
|
@@ -1099,11 +1099,15 @@ interface EditorEvents {
|
|
|
1099
1099
|
type EnableRules = (AnyExtension | string)[] | boolean;
|
|
1100
1100
|
interface EditorOptions {
|
|
1101
1101
|
/**
|
|
1102
|
-
* The element
|
|
1103
|
-
* If `
|
|
1104
|
-
* If
|
|
1105
|
-
|
|
1106
|
-
|
|
1102
|
+
* The element to bind the editor to:
|
|
1103
|
+
* - If an `Element` is passed, the editor will be mounted appended to that element
|
|
1104
|
+
* - If `null` is passed, the editor will not be mounted automatically
|
|
1105
|
+
* - If an object with a `mount` property is passed, the editor will be mounted to that element
|
|
1106
|
+
* - If a function is passed, it will be called with the editor's element, which should place the editor within the document
|
|
1107
|
+
*/
|
|
1108
|
+
element: Element | {
|
|
1109
|
+
mount: HTMLElement;
|
|
1110
|
+
} | ((editor: HTMLElement) => void) | null;
|
|
1107
1111
|
/**
|
|
1108
1112
|
* The content of the editor (HTML, JSON, or a JSON array)
|
|
1109
1113
|
*/
|
package/dist/index.js
CHANGED
|
@@ -4492,7 +4492,7 @@ var Editor = class extends EventEmitter {
|
|
|
4492
4492
|
this.editorState = state;
|
|
4493
4493
|
},
|
|
4494
4494
|
dispatch: (tr) => {
|
|
4495
|
-
this.
|
|
4495
|
+
this.dispatchTransaction(tr);
|
|
4496
4496
|
},
|
|
4497
4497
|
// Stub some commonly accessed properties to prevent errors
|
|
4498
4498
|
composing: false,
|