@tiptap/vue-2 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 +4 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +4 -4
- package/dist/index.js.map +1 -1
- package/dist/menus/index.cjs +6 -13
- package/dist/menus/index.cjs.map +1 -1
- package/dist/menus/index.d.cts +0 -12
- package/dist/menus/index.d.ts +0 -12
- package/dist/menus/index.js +6 -13
- package/dist/menus/index.js.map +1 -1
- package/package.json +7 -7
- package/src/EditorContent.ts +4 -4
package/dist/menus/index.d.cts
CHANGED
|
@@ -93,18 +93,6 @@ interface BubbleMenuPluginProps {
|
|
|
93
93
|
scrollTarget?: HTMLElement | Window;
|
|
94
94
|
};
|
|
95
95
|
}
|
|
96
|
-
declare module '@tiptap/core' {
|
|
97
|
-
interface Commands<ReturnType> {
|
|
98
|
-
bubbleMenu: {
|
|
99
|
-
/**
|
|
100
|
-
* Update the position of the bubble menu. This command is useful to force
|
|
101
|
-
* the bubble menu to update its position in response to certain events
|
|
102
|
-
* (for example, when the bubble menu is resized).
|
|
103
|
-
*/
|
|
104
|
-
updateBubbleMenuPosition: () => ReturnType;
|
|
105
|
-
};
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
96
|
|
|
109
97
|
interface BubbleMenuInterface extends Vue {
|
|
110
98
|
pluginKey: BubbleMenuPluginProps['pluginKey'];
|
package/dist/menus/index.d.ts
CHANGED
|
@@ -93,18 +93,6 @@ interface BubbleMenuPluginProps {
|
|
|
93
93
|
scrollTarget?: HTMLElement | Window;
|
|
94
94
|
};
|
|
95
95
|
}
|
|
96
|
-
declare module '@tiptap/core' {
|
|
97
|
-
interface Commands<ReturnType> {
|
|
98
|
-
bubbleMenu: {
|
|
99
|
-
/**
|
|
100
|
-
* Update the position of the bubble menu. This command is useful to force
|
|
101
|
-
* the bubble menu to update its position in response to certain events
|
|
102
|
-
* (for example, when the bubble menu is resized).
|
|
103
|
-
*/
|
|
104
|
-
updateBubbleMenuPosition: () => ReturnType;
|
|
105
|
-
};
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
96
|
|
|
109
97
|
interface BubbleMenuInterface extends Vue {
|
|
110
98
|
pluginKey: BubbleMenuPluginProps['pluginKey'];
|
package/dist/menus/index.js
CHANGED
|
@@ -1699,6 +1699,12 @@ var BubbleMenuView = class {
|
|
|
1699
1699
|
this.updatePosition();
|
|
1700
1700
|
this.show();
|
|
1701
1701
|
};
|
|
1702
|
+
this.transactionHandler = ({ transaction: tr }) => {
|
|
1703
|
+
const meta = tr.getMeta("bubbleMenu");
|
|
1704
|
+
if (meta === "updatePosition") {
|
|
1705
|
+
this.updatePosition();
|
|
1706
|
+
}
|
|
1707
|
+
};
|
|
1702
1708
|
var _a;
|
|
1703
1709
|
this.editor = editor;
|
|
1704
1710
|
this.element = element;
|
|
@@ -1884,12 +1890,6 @@ var BubbleMenuView = class {
|
|
|
1884
1890
|
}
|
|
1885
1891
|
this.isVisible = false;
|
|
1886
1892
|
}
|
|
1887
|
-
transactionHandler({ transaction: tr }) {
|
|
1888
|
-
const meta = tr.getMeta("bubbleMenu");
|
|
1889
|
-
if (meta === "updatePosition") {
|
|
1890
|
-
this.updatePosition();
|
|
1891
|
-
}
|
|
1892
|
-
}
|
|
1893
1893
|
destroy() {
|
|
1894
1894
|
this.hide();
|
|
1895
1895
|
this.element.removeEventListener("mousedown", this.mousedownHandler, { capture: true });
|
|
@@ -1937,13 +1937,6 @@ var BubbleMenu = Extension.create({
|
|
|
1937
1937
|
shouldShow: this.options.shouldShow
|
|
1938
1938
|
})
|
|
1939
1939
|
];
|
|
1940
|
-
},
|
|
1941
|
-
addCommands() {
|
|
1942
|
-
return {
|
|
1943
|
-
updateBubbleMenuPosition: () => ({ commands }) => {
|
|
1944
|
-
return commands.setMeta("bubbleMenu", "updatePosition");
|
|
1945
|
-
}
|
|
1946
|
-
};
|
|
1947
1940
|
}
|
|
1948
1941
|
});
|
|
1949
1942
|
|